{"Status":true,"Message":"","Response":{"post":{"postuid":"a384b279-ff20-47a1-a13e-3618507a645a","tenantuid":"d8b744fc-2e70-4089-bb80-dd1d08f6c7b2","projectuid":"542e5f51-33cf-401f-aebe-4324ebe36fe4","title":"Create or Update a Web Push Message","slug":"article/create-or-update-a-web-push-message","html":"\u003Cp\u003ECreates or updates a web push message. If the \u003Ccode\u003Eid\u003C/code\u003E in the request body matches an existing message the message is updated; otherwise a new message is created. Returns the id of the created or updated web push message.\u003C/p\u003E\u003Cp\u003EA web push message belongs to a campaign and is sent to contacts who have subscribed to browser notifications for the tenant. See \u003Ca href=\u0022/reference/create-or-update-web-push-opt-in\u0022\u003ECreate or Update Web Push Opt-in\u003C/a\u003E for configuring the prompt that lets contacts subscribe.\u003C/p\u003E\u003Cdiv class=\u0022api_header\u0022\u003EHTTP Request Examples\u003C/div\u003E\u003Cdiv class=\u0022code_wrapper\u0022\u003E\u003Cdiv class=\u0022d-flex header\u0022\u003E\u003C/div\u003E\u003Cdiv class=\u0022code\u0022 data-language=\u0022json\u0022\u003E{\n  \u0026quot;id\u0026quot;: 0,\n  \u0026quot;campaignId\u0026quot;: 3360,\n  \u0026quot;title\u0026quot;: \u0026quot;Flash Sale Today\u0026quot;,\n  \u0026quot;options\u0026quot;: {\n    \u0026quot;body\u0026quot;: \u0026quot;Save 20% on everything. Click to shop.\u0026quot;,\n    \u0026quot;icon\u0026quot;: \u0026quot;https://cdn.example.com/icon.png\u0026quot;,\n    \u0026quot;badge\u0026quot;: \u0026quot;https://cdn.example.com/badge.png\u0026quot;,\n    \u0026quot;click_url\u0026quot;: \u0026quot;https://www.example.com/sale\u0026quot;,\n    \u0026quot;data\u0026quot;: \u0026quot;\u0026quot;\n  },\n  \u0026quot;status\u0026quot;: \u0026quot;Active\u0026quot;\n}\u003C/div\u003E\u003C/div\u003E\u003Cdiv class=\u0022api_header\u0022\u003EHTTP Request Parameters\u003C/div\u003E\u003Csection class=\u0022api_parameters\u0022\u003E\u003Csection class=\u0022api_param\u0022\u003E\u003Cdiv class=\u0022api_param_header\u0022\u003E\u003Cspan class=\u0022p_name\u0022\u003Eid\u003C/span\u003E\u003Cspan class=\u0022p_type\u0022\u003Enumber\u003C/span\u003E\u003C/div\u003E\u003Cdiv\u003EId of the web push message. Omit or set to 0 to create a new message. Supply the existing id to update.\u003C/div\u003E\u003C/section\u003E\u003Csection class=\u0022api_param\u0022\u003E\u003Cdiv class=\u0022api_param_header\u0022\u003E\u003Cspan class=\u0022p_name\u0022\u003EtenantId\u003C/span\u003E\u003Cspan class=\u0022p_type\u0022\u003Enumber\u003C/span\u003E\u003C/div\u003E\u003Cdiv\u003EId of the tenant that owns the message. Inferred from the API key.\u003C/div\u003E\u003C/section\u003E\u003Csection class=\u0022api_param\u0022\u003E\u003Cdiv class=\u0022api_param_header\u0022\u003E\u003Cspan class=\u0022p_name\u0022\u003EcampaignId\u003C/span\u003E\u003Cspan class=\u0022p_type\u0022\u003Enumber\u003C/span\u003E\u003Cspan class=\u0022p_isrequired\u0022\u003Erequired\u003C/span\u003E\u003C/div\u003E\u003Cdiv\u003EId of the campaign this message belongs to.\u003C/div\u003E\u003C/section\u003E\u003Csection class=\u0022api_param\u0022\u003E\u003Cdiv class=\u0022api_param_header\u0022\u003E\u003Cspan class=\u0022p_name\u0022\u003Etitle\u003C/span\u003E\u003Cspan class=\u0022p_type\u0022\u003Estring\u003C/span\u003E\u003Cspan class=\u0022p_isrequired\u0022\u003Erequired\u003C/span\u003E\u003C/div\u003E\u003Cdiv\u003ETitle shown at the top of the push notification. Supports Handlebars merge fields.\u003C/div\u003E\u003C/section\u003E\u003Csection class=\u0022api_param\u0022\u003E\u003Cdiv class=\u0022api_param_header\u0022\u003E\u003Cspan class=\u0022p_name\u0022\u003Eoptions\u003C/span\u003E\u003Cspan class=\u0022p_type\u0022\u003Eobject\u003C/span\u003E\u003Cspan class=\u0022p_isrequired\u0022\u003Erequired\u003C/span\u003E\u003C/div\u003E\u003Cdiv\u003ENotification options. See fields below.\u003C/div\u003E\u003C/section\u003E\u003Csection class=\u0022api_param\u0022\u003E\u003Cdiv class=\u0022api_param_header\u0022\u003E\u003Cspan class=\u0022p_name\u0022\u003Eoptions.body\u003C/span\u003E\u003Cspan class=\u0022p_type\u0022\u003Estring\u003C/span\u003E\u003Cspan class=\u0022p_isrequired\u0022\u003Erequired\u003C/span\u003E\u003C/div\u003E\u003Cdiv\u003EBody text of the push notification. Supports Handlebars merge fields.\u003C/div\u003E\u003C/section\u003E\u003Csection class=\u0022api_param\u0022\u003E\u003Cdiv class=\u0022api_param_header\u0022\u003E\u003Cspan class=\u0022p_name\u0022\u003Eoptions.icon\u003C/span\u003E\u003Cspan class=\u0022p_type\u0022\u003Estring\u003C/span\u003E\u003C/div\u003E\u003Cdiv\u003EURL of the icon shown in the notification. Defaults to the DailyStory logo.\u003C/div\u003E\u003C/section\u003E\u003Csection class=\u0022api_param\u0022\u003E\u003Cdiv class=\u0022api_param_header\u0022\u003E\u003Cspan class=\u0022p_name\u0022\u003Eoptions.badge\u003C/span\u003E\u003Cspan class=\u0022p_type\u0022\u003Estring\u003C/span\u003E\u003C/div\u003E\u003Cdiv\u003EURL of the badge image shown on supported platforms. Defaults to the DailyStory brand badge.\u003C/div\u003E\u003C/section\u003E\u003Csection class=\u0022api_param\u0022\u003E\u003Cdiv class=\u0022api_param_header\u0022\u003E\u003Cspan class=\u0022p_name\u0022\u003Eoptions.click_url\u003C/span\u003E\u003Cspan class=\u0022p_type\u0022\u003Estring\u003C/span\u003E\u003C/div\u003E\u003Cdiv\u003EURL opened when the recipient clicks the notification.\u003C/div\u003E\u003C/section\u003E\u003Csection class=\u0022api_param\u0022\u003E\u003Cdiv class=\u0022api_param_header\u0022\u003E\u003Cspan class=\u0022p_name\u0022\u003Eoptions.data\u003C/span\u003E\u003Cspan class=\u0022p_type\u0022\u003Estring\u003C/span\u003E\u003C/div\u003E\u003Cdiv\u003EOptional string payload delivered with the push event.\u003C/div\u003E\u003C/section\u003E\u003Csection class=\u0022api_param\u0022\u003E\u003Cdiv class=\u0022api_param_header\u0022\u003E\u003Cspan class=\u0022p_name\u0022\u003Estatus\u003C/span\u003E\u003Cspan class=\u0022p_type\u0022\u003Estring\u003C/span\u003E\u003C/div\u003E\u003Cdiv\u003EStatus of the message. Use Active to enable sending, Deleted to soft-delete. Defaults to Active.\u003C/div\u003E\u003C/section\u003E\u003C/section\u003E\u003Cdiv class=\u0022api_header\u0022\u003EHTTP Response Examples\u003C/div\u003E\u003Cdiv class=\u0022code_wrapper\u0022\u003E\u003Cdiv class=\u0022d-flex header\u0022\u003E\u003Cspan class=\u0022httpstatus\u0022\u003E\u003Cspan class=\u0022solid-circle success\u0022\u003E\u003C/span\u003E200\u003C/span\u003E\u003C/div\u003E\u003Cdiv class=\u0022code\u0022 data-language=\u0022json\u0022\u003E{\n  \u0026quot;Status\u0026quot;: true,\n  \u0026quot;Message\u0026quot;: \u0026quot;\u0026quot;,\n  \u0026quot;Response\u0026quot;: {\n    \u0026quot;id\u0026quot;: 1845\n  }\n}\u003C/div\u003E\u003C/div\u003E\u003Cdiv class=\u0022api_header\u0022\u003EHTTP Response Parameters\u003C/div\u003E\u003Csection class=\u0022api_parameters\u0022\u003E\u003Csection class=\u0022api_param\u0022\u003E\u003Cdiv class=\u0022api_param_header\u0022\u003E\u003Cspan class=\u0022p_name\u0022\u003Eid\u003C/span\u003E\u003Cspan class=\u0022p_type\u0022\u003Enumber\u003C/span\u003E\u003Cspan class=\u0022p_isrequired\u0022\u003Erequired\u003C/span\u003E\u003C/div\u003E\u003Cdiv\u003EId of the created or updated web push message.\u003C/div\u003E\u003C/section\u003E\u003C/section\u003E","json_meta":{"api_verb":"POST","api_path":"https://us-1.dailystory.com/api/v1/webhooks/"},"publish_status":0,"post_type":"API","authoruid":"3dde8c16-763a-4a2b-ae0b-1d8c50c62e3d","author":{"authoruid":"3dde8c16-763a-4a2b-ae0b-1d8c50c62e3d"},"featured_image_updating":false,"meta_description":"Create or update web push messages linked to campaigns, managing notifications sent to subscribed contacts with customizable titles, icons, and click actions.","display_toc":true,"has_workingcopy":false,"allow_indexing":true,"sort_order":1,"total_views":0,"date_published":"2026-04-20T21:09:00","date_updated":"2026-04-20T21:11:59.633","date_created":"2026-04-20T21:02:01.593"}}}