अभियान
GET https://webpushke.com/api/campaigns/
curl --request GET \
--url 'https://webpushke.com/api/campaigns/' \
--header 'Authorization: Bearer {api_key}' \
--url 'https://webpushke.com/api/campaigns/' \
--header 'Authorization: Bearer {api_key}' \
पैरामीटर | विवरण | विवरण |
---|---|---|
page | वैकल्पिक पूर्णांक | The page number that you want results from. Defaults to 1 . |
results_per_page | वैकल्पिक पूर्णांक | 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:46:37"
}
],
"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}' \
--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:46:37"
}
}
POST https://webpushke.com/api/campaigns
पैरामीटर | विवरण | विवरण |
---|---|---|
website_id | आवश्यक पूर्णांक | - |
name | आवश्यक डोरी | - |
title | आवश्यक डोरी | - |
description | आवश्यक डोरी | - |
url | वैकल्पिक डोरी | - |
image | वैकल्पिक फ़ाइल | - |
button_title_1 | वैकल्पिक डोरी | - |
button_url_1 | वैकल्पिक डोरी | - |
button_title_2 | वैकल्पिक डोरी | - |
button_url_2 | वैकल्पिक डोरी | - |
is_scheduled | वैकल्पिक बूलियन | - |
scheduled_datetime | वैकल्पिक डोरी | - |
is_silent | वैकल्पिक बूलियन | - |
is_auto_hide | वैकल्पिक बूलियन | - |
ttl | वैकल्पिक डोरी | Allowed values: 0 , 900 , 1800 , 3600 , 10800 , 21600 , 43200 , 86400 , 259200 , 432000 , 604800 , 1209600 , 2419200 |
segment | वैकल्पिक डोरी | Allowed values: all , custom , filter , INT segment_id |
subscribers_ids | वैकल्पिक डोरी | Available when: segment = custom |
filters_custom_parameter_key[index] | वैकल्पिक डोरी | Available when: segment = filter |
filters_custom_parameter_value[index] | वैकल्पिक डोरी | Available when: segment = filter |
filters_custom_parameter_value[index] | वैकल्पिक डोरी | Available when: segment = filter |
filters_subscribed_on_url | वैकल्पिक डोरी | Available when: segment = filter |
filters_cities | वैकल्पिक डोरी | Available when: segment = filter |
filters_countries[] | वैकल्पिक डोरी | Available when: segment = filter |
filters_continents[] | वैकल्पिक डोरी | Available when: segment = filter |
filters_device_type[] | वैकल्पिक डोरी | Available when: segment = filter |
filters_languages[] | वैकल्पिक डोरी | Available when: segment = filter |
filters_operating_systems[] | वैकल्पिक डोरी | Available when: segment = filter |
filters_browsers[] | वैकल्पिक डोरी | Available when: segment = filter |
utm_source | वैकल्पिक डोरी | - |
utm_medium | वैकल्पिक डोरी | - |
utm_campaign | वैकल्पिक डोरी | - |
save | वैकल्पिक बूलियन | मसौदा सेव करें |
send | वैकल्पिक बूलियन | अभियान भेजें |
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' \
--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}
पैरामीटर | विवरण | विवरण |
---|---|---|
website_id | वैकल्पिक पूर्णांक | - |
name | वैकल्पिक डोरी | - |
title | वैकल्पिक डोरी | - |
description | वैकल्पिक डोरी | - |
url | वैकल्पिक डोरी | - |
image | वैकल्पिक फ़ाइल | - |
button_title_1 | वैकल्पिक डोरी | - |
button_url_1 | वैकल्पिक डोरी | - |
button_title_2 | वैकल्पिक डोरी | - |
button_url_2 | वैकल्पिक डोरी | - |
is_scheduled | वैकल्पिक बूलियन | - |
scheduled_datetime | वैकल्पिक डोरी | - |
is_silent | वैकल्पिक बूलियन | - |
is_auto_hide | वैकल्पिक बूलियन | - |
ttl | वैकल्पिक डोरी | Allowed values: 0 , 900 , 1800 , 3600 , 10800 , 21600 , 43200 , 86400 , 259200 , 432000 , 604800 , 1209600 , 2419200 |
segment | वैकल्पिक डोरी | Allowed values: all , custom , filter , INT segment_id |
subscribers_ids | वैकल्पिक डोरी | Available when: segment = custom |
filters_custom_parameter_key[index] | वैकल्पिक डोरी | Available when: segment = filter |
filters_custom_parameter_value[index] | वैकल्पिक डोरी | Available when: segment = filter |
filters_custom_parameter_value[index] | वैकल्पिक डोरी | Available when: segment = filter |
filters_subscribed_on_url | वैकल्पिक डोरी | Available when: segment = filter |
filters_cities | वैकल्पिक डोरी | Available when: segment = filter |
filters_countries[] | वैकल्पिक डोरी | Available when: segment = filter |
filters_continents[] | वैकल्पिक डोरी | Available when: segment = filter |
filters_device_type[] | वैकल्पिक डोरी | Available when: segment = filter |
filters_languages[] | वैकल्पिक डोरी | Available when: segment = filter |
filters_operating_systems[] | वैकल्पिक डोरी | Available when: segment = filter |
filters_browsers[] | वैकल्पिक डोरी | Available when: segment = filter |
utm_source | वैकल्पिक डोरी | - |
utm_medium | वैकल्पिक डोरी | - |
utm_campaign | वैकल्पिक डोरी | - |
save | वैकल्पिक बूलियन | मसौदा सेव करें |
send | वैकल्पिक बूलियन | अभियान भेजें |
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' \
--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}' \
--url 'https://webpushke.com/api/campaigns/{campaign_id}' \
--header 'Authorization: Bearer {api_key}' \