Live Activities

Live Activities display real-time information on the iOS lock screen and Dynamic Island. PushTower makes it simple to start, update, and end Live Activities via the API.

Starting a Live Activity

curl -X POST https://api.pushtower.com/v1/live-activity \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d '{
    "channel": "my-channel",
    "event": "start",
    "content_state": {
      "status": "In Progress",
      "progress": 0.25,
      "message": "Building project..."
    }
  }'

Updating a Live Activity

Send updated content state to refresh the display:

curl -X POST https://api.pushtower.com/v1/live-activity \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d '{
    "channel": "my-channel",
    "event": "update",
    "content_state": {
      "status": "Testing",
      "progress": 0.75,
      "message": "Running test suite..."
    }
  }'

Ending a Live Activity

curl -X POST https://api.pushtower.com/v1/live-activity \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d '{
    "channel": "my-channel",
    "event": "end",
    "content_state": {
      "status": "Complete",
      "progress": 1.0,
      "message": "All tests passed!"
    }
  }'

Use Cases