MessagingPush campaigns
Messaging
Push campaigns
Wallet push campaigns, templates and alerts.
The Campaigns screen for a key: who a wallet push would reach, ideas, saved templates, automatic alerts and campaign status, and sending or scheduling a campaign. The plan, opt-outs and daily limits apply exactly as in the app: 3 campaigns a business and 2 notifications a pass a day.
Wallets report no delivery or read data, so a campaign's numbers are what was sent and what failed.
Paths are relative to https://app.revisit.cards/v1/developer.
Endpoints
- GETCount the customers each push segment holds
/push/segments - GETPreview who an audience reaches
/push/reach - GETRead today's message ideas
/push/suggestions - GETRead the numbers above the composer
/push/stats - GETList recent campaigns and where each stands
/push/campaigns - POSTSend or schedule a push campaign
/push/campaigns - GETRead one campaign and its status
/push/campaigns/{id} - POSTCancel a scheduled campaign
/push/campaigns/{id}/cancel - GETList saved message templates
/push/templates - POSTSave a message template
/push/templates - DELETEDelete a saved template
/push/templates/{id} - GETList the timed alerts
/push/alerts - POSTCreate a timed alert
/push/alerts - PUTChange a timed alert
/push/alerts/{id} - DELETEDelete a timed alert
/push/alerts/{id} - PUTSwitch a timed alert on or off
/push/alerts/{id}/enabled - GETRead the automatic milestone alert settings
/push/milestones - PUTChange the automatic milestone alert settings
/push/milestones
Count the customers each push segment holds
/push/segmentsScopepush:read
Requires push:read and the plan's campaigns feature (403 FEATURE_REQUIRED otherwise; 404 while the push plugin is off for the business). The Campaigns screen's counts: customers who agreed to card updates and can be reached through a wallet, per segment, plus broadcast and everyone. A key limited to several branches or programs must name one with branchId and programId. Counts only: never a name or a phone.
Query
programIduuidbranchIduuid
Errors
- 403
FEATURE_REQUIRED
curl "https://app.revisit.cards/v1/developer/push/segments" \
-H "Authorization: Bearer $DEVELOPER_API_KEY"{
"data": null,
"requestId": "bc85fb18-4aa9-4ab9-910a-9ca5cd42e505",
"success": true
}Preview who an audience reaches
/push/reachScopepush:read
Requires push:read. The preview before a send: how many customers kind (broadcast, all, segment with segment, individual with comma-separated ref membership ids, location with a branch id in ref) reaches on Apple, Google and neither, and campaignsLeftToday of the business's 3 a day. Nothing is sent or reserved.
Query
kindenum- One of
all,broadcast,segment,individual,location. Default"broadcast". segmentenum- One of
lapsed_7,lapsed,one_away,reward_ready,new_week,champions. refstringprogramIduuidbranchIduuid
curl "https://app.revisit.cards/v1/developer/push/reach" \
-H "Authorization: Bearer $DEVELOPER_API_KEY"{
"data": null,
"requestId": "9b9dfa06-3590-4b70-bacc-1686d512a093",
"success": true
}Read today's message ideas
/push/suggestionsScopepush:read
Requires push:read. The ideas the composer proposes from live numbers (audience, title, message, rationale), best first.
Query
programIduuidbranchIduuid
curl "https://app.revisit.cards/v1/developer/push/suggestions" \
-H "Authorization: Bearer $DEVELOPER_API_KEY"{
"data": null,
"requestId": "e8a1bec1-9575-439b-9046-5bdb46e73b4e",
"success": true
}Read the numbers above the composer
/push/statsScopepush:read
Requires push:read. Campaigns sent today against the daily cap (3 a business), the per-pass daily limit (2), scheduled campaigns and customers.
Query
programIduuidbranchIduuid
curl "https://app.revisit.cards/v1/developer/push/stats" \
-H "Authorization: Bearer $DEVELOPER_API_KEY"{
"data": null,
"requestId": "a5dc1d53-a90f-45d9-8f06-f67aa91a816b",
"success": true
}List recent campaigns and where each stands
/push/campaignsScopepush:read
Requires push:read. Newest first, at most limit (50). Only campaigns of the branches and programs the key may use. Each carries a status (scheduled, queued, completed, canceled) and per-platform counts of queued, sent, skipped and failed; wallets report no delivery or read data.
Query
limitinteger- 1 to 50. Default
20. programIduuid
curl "https://app.revisit.cards/v1/developer/push/campaigns" \
-H "Authorization: Bearer $DEVELOPER_API_KEY"{
"data": null,
"requestId": "5e9d7739-fc3a-4ee5-a054-605474aec5e4",
"success": true
}Send or schedule a push campaign
/push/campaignsScopepush:write
Requires push:write. Runs the app's own send: the plan's campaigns feature, opt-outs (broadcast, segment and location reach only customers who agreed to card updates; all is the shop's explicit choice), the copy rules (no links), at most 3 campaigns a business a day (409 CAMPAIGN_LIMIT) and 2 notifications a pass a day (a pass already at the limit is skipped when the sender reaches it). Answers 202 with a stable campaignId and status: the sender runs as a bounded job, so read GET /push/campaigns/{id} for queued or completed. scheduledAt (a minute to 30 days ahead, not for segments) schedules it. A retried Idempotency-Key never creates a second campaign. 409 NO_RECIPIENTS when nobody can be notified. A test key sends nothing real: its campaign ends completed with every delivery skipped as test_workspace. Optional cta puts a button on the pass (preset kinds call, whatsapp, directions, social, website; shorteners and bad values are 422) and optional window shows the card on the lock screen between two times (Apple only, at most 14 days); each is 403 PLUGIN_DISABLED while its plugin switch is off, as in the app. Timed alerts are under /push/alerts.
Send an Idempotency-Key header. Safe to retry.
Body
audienceobjectRequiredaudience.kindenumRequired- One of
all,broadcast,segment,individual,location. audience.segmentenum- One of
lapsed_7,lapsed,one_away,reward_ready,new_week,champions. audience.membershipIdsuuid[]audience.branchIduuidbranchIduuidmessagestringRequiredprogramIduuidscheduledAtdate-timetitlestringRequiredctaobjectcta.kindenumRequired- One of
call,whatsapp,directions,social,website. cta.labelstringcta.valuestringRequired- A phone for call and whatsapp,
<lat>,<lng>for directions, an https address for social and website. 1 to 200 characters. windowobjectwindow.startdate-timeRequiredwindow.enddate-timeRequired
Returns 202
campaignIduuidRequiredqueuedintegerRequiredstatusenumRequired- One of
scheduled,queued,completed,canceled.
Errors
- 409
CAMPAIGN_LIMIT - 409
NO_RECIPIENTS - 403
PLUGIN_DISABLED
curl -X POST "https://app.revisit.cards/v1/developer/push/campaigns" \
-H "Authorization: Bearer $DEVELOPER_API_KEY" \
-H "Idempotency-Key: 5f0c2a8e-7b1d-4c3e-9a6f-0d4b8e47a0aa" \
-H "Content-Type: application/json" \
-d '{
"audience": {
"kind": "all"
},
"message": "Your 10th chai is on us this week.",
"title": "Weekend chai offer"
}'{
"data": {
"campaignId": "59aed7f3-83e8-43d6-aa83-3d0f98813f1a",
"queued": 0,
"status": "scheduled"
},
"requestId": "826f1af9-7c02-45c9-bea8-d2950244e8df",
"success": true
}Read one campaign and its status
/push/campaigns/{id}Scopepush:read
Requires push:read. An id of another business, another environment or outside the key's branches and programs is 404.
Path
iduuidRequired
Returns 200
audienceobjectRequiredaudience.branchIdstring or nullRequiredaudience.kindstringRequiredaudience.segmentstring or nullRequiredbranchIdstring or nullRequiredcanceledAtstring or nullRequiredcanceledReasonstring or nullRequiredcreatedAtstringRequirediduuidRequiredmessagestringRequiredplatformsobjectRequiredplatforms.appleobjectRequiredplatforms.apple.failedintegerRequiredplatforms.apple.queuedintegerRequiredplatforms.apple.sentintegerRequiredplatforms.apple.skippedintegerRequiredplatforms.googleobjectRequiredplatforms.google.failedintegerRequiredplatforms.google.queuedintegerRequiredplatforms.google.sentintegerRequiredplatforms.google.skippedintegerRequiredprogramIdstring or nullRequiredscheduledAtstring or nullRequiredskippedReasonsstring[]RequiredstatusenumRequired- One of
scheduled,queued,completed,canceled. titlestring or nullRequired
curl "https://app.revisit.cards/v1/developer/push/campaigns/e01b010d-2c65-48e1-83a0-acad79f8d3b4" \
-H "Authorization: Bearer $DEVELOPER_API_KEY"{
"data": {
"audience": {
"branchId": "5eff65d7-d01c-4bd3-b26a-3d06b21fd005",
"kind": "segment",
"segment": "lapsed"
},
"branchId": "5eff65d7-d01c-4bd3-b26a-3d06b21fd005",
"canceledAt": null,
"canceledReason": null,
"createdAt": "2026-11-03T08:41:12.000Z",
"id": "e01b010d-2c65-48e1-83a0-acad79f8d3b4",
"message": "Your 10th chai is on us this week.",
"platforms": {
"apple": {
"failed": 2,
"queued": 0,
"sent": 118,
"skipped": 3
},
"google": {
"failed": 2,
"queued": 0,
"sent": 118,
"skipped": 3
}
},
"programId": "d7595bbd-4342-41b4-9037-2e61a9f8403f",
"scheduledAt": "2026-11-03T08:41:12.000Z",
"skippedReasons": [
"daily_limit"
],
"status": "scheduled",
"title": "Weekend chai offer"
},
"requestId": "c3804658-e4d5-4108-9b3a-27b929c1ec14",
"success": true
}Cancel a scheduled campaign
/push/campaigns/{id}/cancelScopepush:write
Requires push:write. Only before it goes out; 409 NOT_SCHEDULED once it went out or was canceled. A retried key replays the first answer.
Send an Idempotency-Key header. Safe to retry.
Path
iduuidRequired
Returns 200
audienceobjectRequiredaudience.branchIdstring or nullRequiredaudience.kindstringRequiredaudience.segmentstring or nullRequiredbranchIdstring or nullRequiredcanceledAtstring or nullRequiredcanceledReasonstring or nullRequiredcreatedAtstringRequirediduuidRequiredmessagestringRequiredplatformsobjectRequiredplatforms.appleobjectRequiredplatforms.apple.failedintegerRequiredplatforms.apple.queuedintegerRequiredplatforms.apple.sentintegerRequiredplatforms.apple.skippedintegerRequiredplatforms.googleobjectRequiredplatforms.google.failedintegerRequiredplatforms.google.queuedintegerRequiredplatforms.google.sentintegerRequiredplatforms.google.skippedintegerRequiredprogramIdstring or nullRequiredscheduledAtstring or nullRequiredskippedReasonsstring[]RequiredstatusenumRequired- One of
scheduled,queued,completed,canceled. titlestring or nullRequired
Errors
- 409
NOT_SCHEDULED
curl -X POST "https://app.revisit.cards/v1/developer/push/campaigns/e01b010d-2c65-48e1-83a0-acad79f8d3b4/cancel" \
-H "Authorization: Bearer $DEVELOPER_API_KEY" \
-H "Idempotency-Key: 5f0c2a8e-7b1d-4c3e-9a6f-0d4b8e1cfdbc"{
"data": {
"audience": {
"branchId": "5eff65d7-d01c-4bd3-b26a-3d06b21fd005",
"kind": "segment",
"segment": "lapsed"
},
"branchId": "5eff65d7-d01c-4bd3-b26a-3d06b21fd005",
"canceledAt": null,
"canceledReason": null,
"createdAt": "2026-11-03T08:41:12.000Z",
"id": "e01b010d-2c65-48e1-83a0-acad79f8d3b4",
"message": "Your 10th chai is on us this week.",
"platforms": {
"apple": {
"failed": 2,
"queued": 0,
"sent": 118,
"skipped": 3
},
"google": {
"failed": 2,
"queued": 0,
"sent": 118,
"skipped": 3
}
},
"programId": "d7595bbd-4342-41b4-9037-2e61a9f8403f",
"scheduledAt": "2026-11-03T08:41:12.000Z",
"skippedReasons": [
"daily_limit"
],
"status": "scheduled",
"title": "Weekend chai offer"
},
"requestId": "95d575c2-0ea0-4892-b0b6-8b87721e574c",
"success": true
}List saved message templates
/push/templatesScopepush:read
Requires push:read and a key with no branch or program limit (templates belong to the whole business).
curl "https://app.revisit.cards/v1/developer/push/templates" \
-H "Authorization: Bearer $DEVELOPER_API_KEY"{
"data": null,
"requestId": "78fec5d4-818e-49c1-bb06-b9c527f1f3d0",
"success": true
}Save a message template
/push/templatesScopepush:write
Requires push:write and a whole-business key. Same copy rules and the same limit of 20 as the app. A retried key replays the first answer.
Send an Idempotency-Key header. Safe to retry.
Body
messagestringRequiredtitlestringRequired
curl -X POST "https://app.revisit.cards/v1/developer/push/templates" \
-H "Authorization: Bearer $DEVELOPER_API_KEY" \
-H "Idempotency-Key: 5f0c2a8e-7b1d-4c3e-9a6f-0d4b8ea5ed6b" \
-H "Content-Type: application/json" \
-d '{
"message": "Your 10th chai is on us this week.",
"title": "Weekend chai offer"
}'{
"data": null,
"requestId": "f05618cb-84f7-4874-a7f1-4c4dcc7f40f3",
"success": true
}Delete a saved template
/push/templates/{id}Scopepush:write
Requires push:write and a whole-business key. 404 once it is gone.
Path
iduuidRequired
curl -X DELETE "https://app.revisit.cards/v1/developer/push/templates/e01b010d-2c65-48e1-83a0-acad79f8d3b4" \
-H "Authorization: Bearer $DEVELOPER_API_KEY"HTTP/1.1 204List the timed alerts
/push/alertsScopepush:read
Requires push:read and a whole-business key. The same alerts the app lists, whoever made them.
curl "https://app.revisit.cards/v1/developer/push/alerts" \
-H "Authorization: Bearer $DEVELOPER_API_KEY"{
"data": null,
"requestId": "16e2e8b8-b727-4cdd-8b9c-3932591f098c",
"success": true
}Create a timed alert
/push/alertsScopepush:write
Requires push:write, an Idempotency-Key and a whole-business key. A message at a start time, once or daily, weekly or monthly, to everyone who agreed to card updates (broadcast), one segment or the customers near one branch; never a list of people. Each run is an ordinary campaign through the app's own rules (the plan, opt-outs, 3 campaigns a day, 2 notifications a pass a day); a run that cannot go out is recorded as the alert's lastStatus and the schedule moves on, and a run later than 2 hours after its time is skipped as missed. At most 10 alerts (409 ALERT_LIMIT). An alert made through the API runs as the integration, not as a person, and its audit rows name the application and key. cta is 403 PLUGIN_DISABLED while buttons are off.
Send an Idempotency-Key header. Safe to retry.
Body
audienceobjectRequiredaudience.kindenumRequired- One of
broadcast,segment,location. audience.segmentenum- One of
lapsed_7,lapsed,one_away,reward_ready,new_week,champions. audience.branchIduuidctaobjectcta.kindenumRequired- One of
call,whatsapp,directions,social,website. cta.labelstringcta.valuestringRequired- A phone for call and whatsapp,
<lat>,<lng>for directions, an https address for social and website. 1 to 200 characters. enabledboolean- Default
true. messagestringRequiredprogramIduuidrepeatenumRequired- One of
once,daily,weekly,monthly. startAtdate-timeRequiredtitlestringRequired
Errors
- 409
ALERT_LIMIT - 403
PLUGIN_DISABLED
curl -X POST "https://app.revisit.cards/v1/developer/push/alerts" \
-H "Authorization: Bearer $DEVELOPER_API_KEY" \
-H "Idempotency-Key: 5f0c2a8e-7b1d-4c3e-9a6f-0d4b8e098659" \
-H "Content-Type: application/json" \
-d '{
"audience": {
"kind": "broadcast"
},
"message": "Your 10th chai is on us this week.",
"repeat": "once",
"startAt": "2026-11-03T08:41:12.000Z",
"title": "Weekend chai offer"
}'{
"data": null,
"requestId": "eb15fe57-a4fd-4d22-b291-e37d0f863d7d",
"success": true
}Change a timed alert
/push/alerts/{id}Scopepush:write
Requires push:write and a whole-business key. Replaces the alert's content; the next run is worked out again.
Path
iduuidRequired
Body
audienceobjectRequiredaudience.kindenumRequired- One of
broadcast,segment,location. audience.segmentenum- One of
lapsed_7,lapsed,one_away,reward_ready,new_week,champions. audience.branchIduuidctaobjectcta.kindenumRequired- One of
call,whatsapp,directions,social,website. cta.labelstringcta.valuestringRequired- A phone for call and whatsapp,
<lat>,<lng>for directions, an https address for social and website. 1 to 200 characters. enabledboolean- Default
true. messagestringRequiredprogramIduuidrepeatenumRequired- One of
once,daily,weekly,monthly. startAtdate-timeRequiredtitlestringRequired
curl -X PUT "https://app.revisit.cards/v1/developer/push/alerts/e01b010d-2c65-48e1-83a0-acad79f8d3b4" \
-H "Authorization: Bearer $DEVELOPER_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"audience": {
"kind": "broadcast"
},
"message": "Your 10th chai is on us this week.",
"repeat": "once",
"startAt": "2026-11-03T08:41:12.000Z",
"title": "Weekend chai offer"
}'{
"data": null,
"requestId": "518fe66e-15cd-4dc2-bbd6-1cb9be164378",
"success": true
}Delete a timed alert
/push/alerts/{id}Scopepush:write
Requires push:write and a whole-business key. Answers 204; an unknown or another business's alert is 404.
Path
iduuidRequired
curl -X DELETE "https://app.revisit.cards/v1/developer/push/alerts/e01b010d-2c65-48e1-83a0-acad79f8d3b4" \
-H "Authorization: Bearer $DEVELOPER_API_KEY"HTTP/1.1 204Switch a timed alert on or off
/push/alerts/{id}/enabledScopepush:write
Requires push:write and a whole-business key. Switching on resumes at the next run on the alert's own rhythm; a finished one-time alert is 409 ALERT_FINISHED.
Path
iduuidRequired
Body
enabledbooleanRequired
Errors
- 409
ALERT_FINISHED
curl -X PUT "https://app.revisit.cards/v1/developer/push/alerts/e01b010d-2c65-48e1-83a0-acad79f8d3b4/enabled" \
-H "Authorization: Bearer $DEVELOPER_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"enabled": false
}'{
"data": null,
"requestId": "7bd39a09-9af9-4ec6-8935-f0ed8305a91e",
"success": true
}Read the automatic milestone alert settings
/push/milestonesScopepush:read
Requires push:read and a whole-business key. Every event with its stored settings over the defaults (off, English).
curl "https://app.revisit.cards/v1/developer/push/milestones" \
-H "Authorization: Bearer $DEVELOPER_API_KEY"{
"data": null,
"requestId": "4c69dcc2-43d5-4e0d-b7a3-1ab0afdbcbf6",
"success": true
}Change the automatic milestone alert settings
/push/milestonesScopepush:write
Requires push:write and a whole-business key. Sets exactly the settings sent; the same copy rules as the app. Repeating it changes nothing.
Body
settingsobject[]Requiredsettings[].enabledbooleanRequiredsettings[].eventenumRequired- One of
one_away,reward_ready,reward_redeemed,reward_expiring. settings[].languageenumRequired- One of
en,banglish. settings[].messagestring or nullRequiredsettings[].titlestring or nullRequired
curl -X PUT "https://app.revisit.cards/v1/developer/push/milestones" \
-H "Authorization: Bearer $DEVELOPER_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"settings": [
{
"enabled": false,
"event": "one_away",
"language": "en",
"message": "Your 10th chai is on us this week.",
"title": "Weekend chai offer"
}
]
}'{
"data": null,
"requestId": "cae82f24-0f0a-424d-9c72-fee1f468e03b",
"success": true
}