Widgets
Duplicate Popup
Copy a popup into a new draft
POST
/
api
/
v1
/
popups
/
{popupId}
/
duplicate
Duplicate Popup
curl --request POST \
--url https://api.sequenzy.com/api/v1/popups/{popupId}/duplicate \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>"
}
'import requests
url = "https://api.sequenzy.com/api/v1/popups/{popupId}/duplicate"
payload = { "name": "<string>" }
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>'})
};
fetch('https://api.sequenzy.com/api/v1/popups/{popupId}/duplicate', 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/{popupId}/duplicate",
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>'
]),
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/{popupId}/duplicate"
payload := strings.NewReader("{\n \"name\": \"<string>\"\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/{popupId}/duplicate")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sequenzy.com/api/v1/popups/{popupId}/duplicate")
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}"
response = http.request(request)
puts response.read_body{
"success": true,
"popup": {
"id": "pop_456",
"name": "Welcome offer v2",
"status": "draft",
"viewCount": 0,
"conversionCount": 0,
"stats": {
"views": 0,
"starts": 0,
"conversions": 0,
"startRate": null,
"conversionRate": null,
"completionRate": null
}
},
"message": "Popup duplicated as a draft with its own stats. Set status to published when the copy is ready to show."
}
{ "error": "Popup name is required." }
{
"error": "Missing API key. Provide via x-api-key header or Authorization: Bearer <key>"
}
{ "error": "API key is missing required scope: widgets:write" }
{ "error": "Popup not found" }
Copy a saved popup into a new draft with its own view and conversion counts.
The original keeps its status and stats, so a live popup carries on showing
while you edit the copy.
Use this to test a new offer or headline against a popup that already performs.
Publish the copy when it is ready with
Update Popup.
Request
string
Name for the copy. Defaults to the original name with
(copy) appended.curl -X POST "https://api.sequenzy.com/api/v1/popups/pop_123/duplicate" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "name": "Welcome offer v2" }'
Responses
{
"success": true,
"popup": {
"id": "pop_456",
"name": "Welcome offer v2",
"status": "draft",
"viewCount": 0,
"conversionCount": 0,
"stats": {
"views": 0,
"starts": 0,
"conversions": 0,
"startRate": null,
"conversionRate": null,
"completionRate": null
}
},
"message": "Popup duplicated as a draft with its own stats. Set status to published when the copy is ready to show."
}
{ "error": "Popup name is required." }
{
"error": "Missing API key. Provide via x-api-key header or Authorization: Bearer <key>"
}
{ "error": "API key is missing required scope: widgets:write" }
{ "error": "Popup not found" }
⌘I
Duplicate Popup
curl --request POST \
--url https://api.sequenzy.com/api/v1/popups/{popupId}/duplicate \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>"
}
'import requests
url = "https://api.sequenzy.com/api/v1/popups/{popupId}/duplicate"
payload = { "name": "<string>" }
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>'})
};
fetch('https://api.sequenzy.com/api/v1/popups/{popupId}/duplicate', 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/{popupId}/duplicate",
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>'
]),
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/{popupId}/duplicate"
payload := strings.NewReader("{\n \"name\": \"<string>\"\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/{popupId}/duplicate")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.sequenzy.com/api/v1/popups/{popupId}/duplicate")
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}"
response = http.request(request)
puts response.read_body{
"success": true,
"popup": {
"id": "pop_456",
"name": "Welcome offer v2",
"status": "draft",
"viewCount": 0,
"conversionCount": 0,
"stats": {
"views": 0,
"starts": 0,
"conversions": 0,
"startRate": null,
"conversionRate": null,
"completionRate": null
}
},
"message": "Popup duplicated as a draft with its own stats. Set status to published when the copy is ready to show."
}
{ "error": "Popup name is required." }
{
"error": "Missing API key. Provide via x-api-key header or Authorization: Bearer <key>"
}
{ "error": "API key is missing required scope: widgets:write" }
{ "error": "Popup not found" }