Campagne

GET https://webpushke.com/api/campaigns/
curl --request GET \
--url 'https://webpushke.com/api/campaigns/' \
--header 'Authorization: Bearer {api_key}' \
Parametri Dettagli Descrizione
page Opzionale Intero The page number that you want results from. Defaults to 1.
results_per_page Opzionale Intero How many results you want per page. Allowed values are: 10 , 25 , 50 , 100 , 250 , 500 , 1000. Defaults to 25.
{ "data": [ { "id": 1, "user_id": 1, "website_id": 1, "name": "API Sample", "title": "Sample message", "description": "This is coming from the API.", "url": "https://example.com", "image_url": null, "segment": "all", "settings": { "is_scheduled": 0, "ttl": 2419200, "urgency": "normal", "is_silent": 0, "is_auto_hide": 0, "button_title_1": "", "button_url_1": "", "button_title_2": "", "button_url_2": "" }, "subscribers_ids": [ 1,2,3,4,5 ], "sent_subscribers_ids": [], "total_sent_push_notifications": 0, "total_push_notifications": 1, "total_displayed_push_notifications": 0, "total_clicked_push_notifications": 0, "total_closed_push_notifications": 0, "status": "draft", "scheduled_datetime": "2024-08-09 00:16:22", "last_sent_datetime": null, "last_datetime": null, "datetime": "2025-04-04 18:43:10" } ], "meta": { "page": 1, "results_per_page": 25, "total": 1, "total_pages": 1 }, "links": { "first": "https://webpushke.com/api/campaigns?&page=1", "last": "https://webpushke.com/api/campaigns?&page=1", "next": null, "prev": null, "self": "https://webpushke.com/api/campaigns?&page=1" } }
GET https://webpushke.com/api/campaigns/{campaign_id}
curl --request GET \
--url 'https://webpushke.com/api/campaigns/{campaign_id}' \
--header 'Authorization: Bearer {api_key}' \
{ "data": { "id": 1, "user_id": 1, "website_id": 1, "name": "API Sample", "title": "Sample message", "description": "This is coming from the API.", "url": "https://example.com", "image_url": null, "segment": "all", "settings": { "is_scheduled": 0, "ttl": 2419200, "urgency": "normal", "is_silent": 0, "is_auto_hide": 0, "button_title_1": "", "button_url_1": "", "button_title_2": "", "button_url_2": "" }, "subscribers_ids": [ 1,2,3,4,5 ], "sent_subscribers_ids": [], "total_sent_push_notifications": 0, "total_push_notifications": 1, "total_displayed_push_notifications": 0, "total_clicked_push_notifications": 0, "total_closed_push_notifications": 0, "status": "draft", "scheduled_datetime": "2024-08-09 00:16:22", "last_sent_datetime": null, "last_datetime": null, "datetime": "2025-04-04 18:43:10" } }
POST https://webpushke.com/api/campaigns
Parametri Dettagli Descrizione
website_id Required Intero -
name Required Corda -
title Required Corda -
description Required Corda -
url Opzionale Corda -
image Opzionale File -
button_title_1 Opzionale Corda -
button_url_1 Opzionale Corda -
button_title_2 Opzionale Corda -
button_url_2 Opzionale Corda -
is_scheduled Opzionale Boolean -
scheduled_datetime Opzionale Corda -
is_silent Opzionale Boolean -
is_auto_hide Opzionale Boolean -
ttl Opzionale Corda Allowed values: 0 , 900 , 1800 , 3600 , 10800 , 21600 , 43200 , 86400 , 259200 , 432000 , 604800 , 1209600 , 2419200
segment Opzionale Corda Allowed values: all , custom , filter , INT segment_id
subscribers_ids Opzionale Corda Available when: segment = custom
filters_custom_parameter_key[index] Opzionale Corda Available when: segment = filter
filters_custom_parameter_value[index] Opzionale Corda Available when: segment = filter
filters_custom_parameter_value[index] Opzionale Corda Available when: segment = filter
filters_subscribed_on_url Opzionale Corda Available when: segment = filter
filters_cities Opzionale Corda Available when: segment = filter
filters_countries[] Opzionale Corda Available when: segment = filter
filters_continents[] Opzionale Corda Available when: segment = filter
filters_device_type[] Opzionale Corda Available when: segment = filter
filters_languages[] Opzionale Corda Available when: segment = filter
filters_operating_systems[] Opzionale Corda Available when: segment = filter
filters_browsers[] Opzionale Corda Available when: segment = filter
utm_source Opzionale Corda -
utm_medium Opzionale Corda -
utm_campaign Opzionale Corda -
save Opzionale Boolean Salva bozza
send Opzionale Boolean Invia campagna
curl --request POST \
--url 'https://webpushke.com/api/campaigns' \
--header 'Authorization: Bearer {api_key}' \
--header 'Content-Type: multipart/form-data' \
--form 'name=Example name' \
--form 'website_id=1' \
--form 'title=Example title' \
--form 'description=Example description' \
{ "data": { "id": 1 } }
POST https://webpushke.com/api/campaigns/{campaign_id}
Parametri Dettagli Descrizione
website_id Opzionale Intero -
name Opzionale Corda -
title Opzionale Corda -
description Opzionale Corda -
url Opzionale Corda -
image Opzionale File -
button_title_1 Opzionale Corda -
button_url_1 Opzionale Corda -
button_title_2 Opzionale Corda -
button_url_2 Opzionale Corda -
is_scheduled Opzionale Boolean -
scheduled_datetime Opzionale Corda -
is_silent Opzionale Boolean -
is_auto_hide Opzionale Boolean -
ttl Opzionale Corda Allowed values: 0 , 900 , 1800 , 3600 , 10800 , 21600 , 43200 , 86400 , 259200 , 432000 , 604800 , 1209600 , 2419200
segment Opzionale Corda Allowed values: all , custom , filter , INT segment_id
subscribers_ids Opzionale Corda Available when: segment = custom
filters_custom_parameter_key[index] Opzionale Corda Available when: segment = filter
filters_custom_parameter_value[index] Opzionale Corda Available when: segment = filter
filters_custom_parameter_value[index] Opzionale Corda Available when: segment = filter
filters_subscribed_on_url Opzionale Corda Available when: segment = filter
filters_cities Opzionale Corda Available when: segment = filter
filters_countries[] Opzionale Corda Available when: segment = filter
filters_continents[] Opzionale Corda Available when: segment = filter
filters_device_type[] Opzionale Corda Available when: segment = filter
filters_languages[] Opzionale Corda Available when: segment = filter
filters_operating_systems[] Opzionale Corda Available when: segment = filter
filters_browsers[] Opzionale Corda Available when: segment = filter
utm_source Opzionale Corda -
utm_medium Opzionale Corda -
utm_campaign Opzionale Corda -
save Opzionale Boolean Salva bozza
send Opzionale Boolean Invia campagna
curl --request POST \
--url 'https://webpushke.com/api/campaigns/{campaign_id}' \
--header 'Authorization: Bearer {api_key}' \
--header 'Content-Type: multipart/form-data' \
--form 'name=Example name' \
--form 'website_id=1' \
--form 'title=Example title' \
--form 'description=Example description' \
{ "data": { "id": 1 } }
DELETE https://webpushke.com/api/campaigns/{campaign_id}
curl --request DELETE \
--url 'https://webpushke.com/api/campaigns/{campaign_id}' \
--header 'Authorization: Bearer {api_key}' \