Widgets
Create Popup
Create an on-site signup popup and get its embed script
POST
/
api
/
v1
/
popups
Create Popup
curl --request POST \
--url https://api.sequenzy.com/api/v1/popups \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"template": "<string>",
"status": "<string>",
"listIds": [
"<string>"
],
"tagIds": [
"<string>"
],
"duplicateStrategy": "<string>",
"headline": "<string>",
"description": "<string>",
"buttonText": "<string>",
"successMessage": "<string>",
"redirectUrl": "<string>",
"presentation": "<string>",
"placement": "<string>",
"trigger": {},
"targeting": {},
"schedule": {},
"frequency": {},
"visual": {},
"theme": {},
"blocks": [
{}
]
}
'import requests
url = "https://api.sequenzy.com/api/v1/popups"
payload = {
"name": "<string>",
"template": "<string>",
"status": "<string>",
"listIds": ["<string>"],
"tagIds": ["<string>"],
"duplicateStrategy": "<string>",
"headline": "<string>",
"description": "<string>",
"buttonText": "<string>",
"successMessage": "<string>",
"redirectUrl": "<string>",
"presentation": "<string>",
"placement": "<string>",
"trigger": {},
"targeting": {},
"schedule": {},
"frequency": {},
"visual": {},
"theme": {},
"blocks": [{}]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
template: '<string>',
status: '<string>',
listIds: ['<string>'],
tagIds: ['<string>'],
duplicateStrategy: '<string>',
headline: '<string>',
description: '<string>',
buttonText: '<string>',
successMessage: '<string>',
redirectUrl: '<string>',
presentation: '<string>',
placement: '<string>',
trigger: {},
targeting: {},
schedule: {},
frequency: {},
visual: {},
theme: {},
blocks: [{}]
})
};
fetch('https://api.sequenzy.com/api/v1/popups', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.sequenzy.com/api/v1/popups",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'template' => '<string>',
'status' => '<string>',
'listIds' => [
'<string>'
],
'tagIds' => [
'<string>'
],
'duplicateStrategy' => '<string>',
'headline' => '<string>',
'description' => '<string>',
'buttonText' => '<string>',
'successMessage' => '<string>',
'redirectUrl' => '<string>',
'presentation' => '<string>',
'placement' => '<string>',
'trigger' => [
],
'targeting' => [
],
'schedule' => [
],
'frequency' => [
],
'visual' => [
],
'theme' => [
],
'blocks' => [
[
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.sequenzy.com/api/v1/popups"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"template\": \"<string>\",\n \"status\": \"<string>\",\n \"listIds\": [\n \"<string>\"\n ],\n \"tagIds\": [\n \"<string>\"\n ],\n \"duplicateStrategy\": \"<string>\",\n \"headline\": \"<string>\",\n \"description\": \"<string>\",\n \"buttonText\": \"<string>\",\n \"successMessage\": \"<string>\",\n \"redirectUrl\": \"<string>\",\n \"presentation\": \"<string>\",\n \"placement\": \"<string>\",\n \"trigger\": {},\n \"targeting\": {},\n \"schedule\": {},\n \"frequency\": {},\n \"visual\": {},\n \"theme\": {},\n \"blocks\": [\n {}\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.sequenzy.com/api/v1/popups")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"template\": \"<string>\",\n \"status\": \"<string>\",\n \"listIds\": [\n \"<string>\"\n ],\n \"tagIds\": [\n \"<string>\"\n ],\n \"duplicateStrategy\": \"<string>\",\n \"headline\": \"<string>\",\n \"description\": \"<string>\",\n \"buttonText\": \"<string>\",\n \"successMessage\": \"<string>\",\n \"redirectUrl\": \"<string>\",\n \"presentation\": \"<string>\",\n \"placement\": \"<string>\",\n \"trigger\": {},\n \"targeting\": {},\n \"schedule\": {},\n \"frequency\": {},\n \"visual\": {},\n \"theme\": {},\n \"blocks\": [\n {}\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sequenzy.com/api/v1/popups")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"template\": \"<string>\",\n \"status\": \"<string>\",\n \"listIds\": [\n \"<string>\"\n ],\n \"tagIds\": [\n \"<string>\"\n ],\n \"duplicateStrategy\": \"<string>\",\n \"headline\": \"<string>\",\n \"description\": \"<string>\",\n \"buttonText\": \"<string>\",\n \"successMessage\": \"<string>\",\n \"redirectUrl\": \"<string>\",\n \"presentation\": \"<string>\",\n \"placement\": \"<string>\",\n \"trigger\": {},\n \"targeting\": {},\n \"schedule\": {},\n \"frequency\": {},\n \"visual\": {},\n \"theme\": {},\n \"blocks\": [\n {}\n ]\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"popup": {
"id": "pop_123",
"name": "Welcome offer",
"status": "published",
"viewCount": 0,
"conversionCount": 0,
"publishedAt": "2026-08-10T09:00:00.000Z"
},
"embed": {
"scriptUrl": "https://sequenzy.com/embed/popups/pop_123?v=capture-runtime-20260716-14",
"javascript": "<script async src=\"https://sequenzy.com/embed/popups/pop_123?v=capture-runtime-20260716-14\"></script>",
"supportedPlatforms": ["HTML", "React", "Next.js", "WordPress", "Shopify"]
},
"message": "Popup created and published. Add the embed script to the site and the popup starts showing under its trigger and targeting rules."
}
{ "error": "Every listId must belong to the selected company." }
{
"error": "Missing API key. Provide via x-api-key header or Authorization: Bearer <key>"
}
{ "error": "API key is missing required scope: widgets:write" }
{ "error": "Failed to create popup." }
Create a saved popup and get the one-line script tag that deploys it. The popup
is published by default, so the script is live as soon as it is added to the
site. Trigger, targeting, audience, and duplicate handling stay server-side, so
the deployed script carries no API key.
Omit
listIds to capture into every list, matching the dashboard default.
Request
string
required
Internal popup name.
string
Starting design:
newsletter-modal, discount-offer, countdown-launch,
minimal-slide-in, exit-lead-magnet, live-demo, launch-modal,
paper-digest, stark-takeover, top-bar, announcement-bar, or
fullscreen-welcome. Defaults to newsletter-modal.string
draft or published. Defaults to published.string[]
Lists every signup joins. Omit or pass an empty array to capture into every
list.
string[]
Existing tag IDs to apply.
string
skip, merge, or overwrite. Defaults to skip.string
Text for the popup’s first heading block.
string
Text for the popup’s first paragraph block.
string
Submit button label.
string
Confirmation shown when
redirectUrl is omitted.string
Optional HTTP or HTTPS success redirect.
string
modal, slide-in, floating-bar, or fullscreen.string
center, left, right, top, or bottom.object
When the popup opens:
{ "type": "delay" | "scroll" | "exit-intent" | "click" | "manual", "delaySeconds": 0-3600, "scrollPercent": 1-100, "clickSelector": "#join" }. A click trigger requires a clickSelector.object
Where it may show:
{ "domains": [], "paths": [], "excludedPaths": [], "device": "all" | "desktop" | "mobile" }. Empty arrays mean no restriction.object
Optional run window:
{ "startsAt": "2026-09-01T00:00:00Z", "endsAt": "2026-09-08T00:00:00Z" }. endsAt must be later than startsAt.object
How often one visitor sees it:
{ "maxDisplays": 1-100, "windowDays": 1-365 }.object
Media panel and urgency treatment:
{ "style": "none" | "accent" | "header" | "rail" | "image" | "countdown", "placement": "top" | "left" | "center" | "right", "imageUrl": "https://...", "imageAlt": "...", "countdownMinutes": 1-10080 }.object
Visual theme overrides:
accentColor, backgroundColor, textColor,
mutedTextColor, cardColor, borderColor (all #rrggbb), borderRadius
(0-32), headingFontFamily, bodyFontFamily, density.object[]
Complete replacement for the popup’s content blocks. The popup must keep
exactly one required email field and one submit button.
curl -X POST "https://api.sequenzy.com/api/v1/popups" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "Welcome offer",
"template": "discount-offer",
"listIds": ["list_123"],
"headline": "Take 10% off your first order",
"trigger": { "type": "exit-intent" }
}'
Responses
{
"success": true,
"popup": {
"id": "pop_123",
"name": "Welcome offer",
"status": "published",
"viewCount": 0,
"conversionCount": 0,
"publishedAt": "2026-08-10T09:00:00.000Z"
},
"embed": {
"scriptUrl": "https://sequenzy.com/embed/popups/pop_123?v=capture-runtime-20260716-14",
"javascript": "<script async src=\"https://sequenzy.com/embed/popups/pop_123?v=capture-runtime-20260716-14\"></script>",
"supportedPlatforms": ["HTML", "React", "Next.js", "WordPress", "Shopify"]
},
"message": "Popup created and published. Add the embed script to the site and the popup starts showing under its trigger and targeting rules."
}
{ "error": "Every listId must belong to the selected company." }
{
"error": "Missing API key. Provide via x-api-key header or Authorization: Bearer <key>"
}
{ "error": "API key is missing required scope: widgets:write" }
{ "error": "Failed to create popup." }
⌘I
Create Popup
curl --request POST \
--url https://api.sequenzy.com/api/v1/popups \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"template": "<string>",
"status": "<string>",
"listIds": [
"<string>"
],
"tagIds": [
"<string>"
],
"duplicateStrategy": "<string>",
"headline": "<string>",
"description": "<string>",
"buttonText": "<string>",
"successMessage": "<string>",
"redirectUrl": "<string>",
"presentation": "<string>",
"placement": "<string>",
"trigger": {},
"targeting": {},
"schedule": {},
"frequency": {},
"visual": {},
"theme": {},
"blocks": [
{}
]
}
'import requests
url = "https://api.sequenzy.com/api/v1/popups"
payload = {
"name": "<string>",
"template": "<string>",
"status": "<string>",
"listIds": ["<string>"],
"tagIds": ["<string>"],
"duplicateStrategy": "<string>",
"headline": "<string>",
"description": "<string>",
"buttonText": "<string>",
"successMessage": "<string>",
"redirectUrl": "<string>",
"presentation": "<string>",
"placement": "<string>",
"trigger": {},
"targeting": {},
"schedule": {},
"frequency": {},
"visual": {},
"theme": {},
"blocks": [{}]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
template: '<string>',
status: '<string>',
listIds: ['<string>'],
tagIds: ['<string>'],
duplicateStrategy: '<string>',
headline: '<string>',
description: '<string>',
buttonText: '<string>',
successMessage: '<string>',
redirectUrl: '<string>',
presentation: '<string>',
placement: '<string>',
trigger: {},
targeting: {},
schedule: {},
frequency: {},
visual: {},
theme: {},
blocks: [{}]
})
};
fetch('https://api.sequenzy.com/api/v1/popups', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.sequenzy.com/api/v1/popups",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'template' => '<string>',
'status' => '<string>',
'listIds' => [
'<string>'
],
'tagIds' => [
'<string>'
],
'duplicateStrategy' => '<string>',
'headline' => '<string>',
'description' => '<string>',
'buttonText' => '<string>',
'successMessage' => '<string>',
'redirectUrl' => '<string>',
'presentation' => '<string>',
'placement' => '<string>',
'trigger' => [
],
'targeting' => [
],
'schedule' => [
],
'frequency' => [
],
'visual' => [
],
'theme' => [
],
'blocks' => [
[
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.sequenzy.com/api/v1/popups"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"template\": \"<string>\",\n \"status\": \"<string>\",\n \"listIds\": [\n \"<string>\"\n ],\n \"tagIds\": [\n \"<string>\"\n ],\n \"duplicateStrategy\": \"<string>\",\n \"headline\": \"<string>\",\n \"description\": \"<string>\",\n \"buttonText\": \"<string>\",\n \"successMessage\": \"<string>\",\n \"redirectUrl\": \"<string>\",\n \"presentation\": \"<string>\",\n \"placement\": \"<string>\",\n \"trigger\": {},\n \"targeting\": {},\n \"schedule\": {},\n \"frequency\": {},\n \"visual\": {},\n \"theme\": {},\n \"blocks\": [\n {}\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.sequenzy.com/api/v1/popups")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"template\": \"<string>\",\n \"status\": \"<string>\",\n \"listIds\": [\n \"<string>\"\n ],\n \"tagIds\": [\n \"<string>\"\n ],\n \"duplicateStrategy\": \"<string>\",\n \"headline\": \"<string>\",\n \"description\": \"<string>\",\n \"buttonText\": \"<string>\",\n \"successMessage\": \"<string>\",\n \"redirectUrl\": \"<string>\",\n \"presentation\": \"<string>\",\n \"placement\": \"<string>\",\n \"trigger\": {},\n \"targeting\": {},\n \"schedule\": {},\n \"frequency\": {},\n \"visual\": {},\n \"theme\": {},\n \"blocks\": [\n {}\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sequenzy.com/api/v1/popups")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"template\": \"<string>\",\n \"status\": \"<string>\",\n \"listIds\": [\n \"<string>\"\n ],\n \"tagIds\": [\n \"<string>\"\n ],\n \"duplicateStrategy\": \"<string>\",\n \"headline\": \"<string>\",\n \"description\": \"<string>\",\n \"buttonText\": \"<string>\",\n \"successMessage\": \"<string>\",\n \"redirectUrl\": \"<string>\",\n \"presentation\": \"<string>\",\n \"placement\": \"<string>\",\n \"trigger\": {},\n \"targeting\": {},\n \"schedule\": {},\n \"frequency\": {},\n \"visual\": {},\n \"theme\": {},\n \"blocks\": [\n {}\n ]\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"popup": {
"id": "pop_123",
"name": "Welcome offer",
"status": "published",
"viewCount": 0,
"conversionCount": 0,
"publishedAt": "2026-08-10T09:00:00.000Z"
},
"embed": {
"scriptUrl": "https://sequenzy.com/embed/popups/pop_123?v=capture-runtime-20260716-14",
"javascript": "<script async src=\"https://sequenzy.com/embed/popups/pop_123?v=capture-runtime-20260716-14\"></script>",
"supportedPlatforms": ["HTML", "React", "Next.js", "WordPress", "Shopify"]
},
"message": "Popup created and published. Add the embed script to the site and the popup starts showing under its trigger and targeting rules."
}
{ "error": "Every listId must belong to the selected company." }
{
"error": "Missing API key. Provide via x-api-key header or Authorization: Bearer <key>"
}
{ "error": "API key is missing required scope: widgets:write" }
{ "error": "Failed to create popup." }