POST /api/end
Dismiss one or more activities from the device.
Ends always alert. The record is kept, so a fresh start for the same user works any time.
By activity id
Merge one last state in before the activity dismisses.
1 2 3 4 5 6 7 8 9 10 11 12 13
curl -X POST https://api.webliveactivity.com/api/end \ -H 'Content-Type: application/json' \ -H 'x-api-key: wla_your_key' \ -d '{ "activityId": "act-8f2c1a", "widgetContainerId": "acme-orders", "finalState": { "primaryText": "Delivered", "stage": "Done", "progress": 1, "isComplete": true } }'
By multiple activity ids
Pass an array of ids to end several activities with the same final state.
1 2 3 4 5 6 7 8 9 10 11 12 13 14
curl -X POST https://api.webliveactivity.com/api/end \ -H 'Content-Type: application/json' \ -H 'x-api-key: wla_your_key' \ -d '{ "activityIds": [ "act-8f2c1a", "act-9k4d2b" ], "widgetContainerId": "acme-orders", "finalState": { "primaryText": "Cancelled", "isComplete": true } }'
By group
Dismiss every activity in the group at once.
1 2 3 4 5 6 7
curl -X POST https://api.webliveactivity.com/api/end \ -H 'Content-Type: application/json' \ -H 'x-api-key: wla_your_key' \ -d '{ "group": "order-tracker", "widgetContainerId": "acme-orders" }'
Response
Returns { ok, targeted, unknown }.
1 2 3 4 5
{ "ok": true, "targeted": 1, "unknown": [] }
Examples
End without a final state
Dismiss immediately, keeping whatever the activity last showed.
1 2 3 4 5 6 7
curl -X POST https://api.webliveactivity.com/api/end \ -H 'Content-Type: application/json' \ -H 'x-api-key: wla_your_key' \ -d '{ "activityId": "act-8f2c1a", "widgetContainerId": "acme-orders" }'
End a versus matchup
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
curl -X POST https://api.webliveactivity.com/api/end \ -H 'Content-Type: application/json' \ -H 'x-api-key: wla_your_key' \ -d '{ "activityId": "act-8f2c1a", "widgetContainerId": "csgo-scores", "finalState": { "primaryText": "Match over", "isComplete": true, "versus": { "leftScore": "16", "rightScore": "14", "leftStatus": "Winner" } } }'









