The state object

Every field that controls what the card shows on the phone.

state is what the card shows. Which layout shows which field is in layouts. The rules:

  • On an update (and an end's finalState), the fields sent merge into the saved state. Fields not sent keep their value.
  • versus merges the same way, one level down. segments is replaced whole.
  • To clear a field, send it as "" (or [] for segments).
  • The whole state must be 16KB or less.

Android draws a system notification from the text, accent color, icon, Picture photo, progress bar, scores, league logo, and action button. Fields marked iPhone only do nothing on Android.

Layout and text

FieldTypeDefaultInstructions
layoutstringprogressprogress, picture, versus, or countdown. Set it on start. Change it on an update to switch the type.
primaryTextstring""The headline on Progress, the caption on Picture. Also the title of every alert, so set it on every layout.
secondaryTextstring""The line under the headline, and the body of every alert. On Countdown, the name next to the clock.
stagestringnoneA short word for the current step ("On the way"). iPhone shows it in the compact Dynamic Island, on Progress only. Android 16 shows it in the status chip. Keep it near 7 characters.
isCompletebooleanfalsetrue for the final state. Progress shows "Done" in the compact Dynamic Island. The card stays until it is ended.

Colors

Colors are #RRGGBB text. There is no text color field: text turns black or white to stay readable. The Dynamic Island is always dark.

FieldTypeDefaultInstructions
accentColorHexstringblueThe brand color: the progress bar, tints, and the Android accent. On a custom background color, the bar is black or white instead. brand.color sets it when the state does not.
backgroundColorHexstringblackThe Lock Screen background (Progress, Versus, Countdown). iPhone only.
backgroundGradientHexstringnoneA second color. With backgroundColorHex, the background becomes a gradient (Progress, Versus, Countdown). iPhone only.

Images

Image fields take a full https URL the phone can download. Use WebP. Shapes and sizes are in images that fit. A new image URL on an update restarts the card, so keep URLs the same between calls.

FieldTypeDefaultInstructions
headerIconUrlstringnoneThe logo on Progress and Countdown, and the small mark on Picture. Drawn as a rounded square.
backgroundImageUrlstringnoneA full-size image behind the card: the Picture photo, or a Progress or Versus background. A dark layer keeps text readable. Countdown does not show it.
lockScreenImageUrlstringnoneA Lock Screen version of headerIconUrl, when the Lock Screen needs a different image than the dark Dynamic Island. Used by Progress and Picture.
islandImageUrlstringnonePicture only. A separate photo for the Dynamic Island, which is smaller than the Lock Screen. Falls back to the Lock Screen photo. iPhone only.
androidIconUrlstringnoneReplaces headerIconUrl on Android.
androidImageUrlstringnoneReplaces backgroundImageUrl on Android. Picture shows it as the expanded photo.
immersivebooleanfalsetrue removes the dark layer over backgroundImageUrl. Use it only with dark art. iPhone only.

Progress

FieldTypeDefaultInstructions
progressnumber0Bar fill from 0 to 1. With segments in the segmented style, the share of complete steps is used instead.
progressStylestringsegmentedsegmented (one capsule per step) or linear (one bar, its ends labeled with the first and last step labels).
segmentsobject[]noneThe steps, each { "label": string, "complete": boolean }. Up to 12. Send the full list on every update.
estimatedMinutesnumbernoneWhole minutes. Shows "N min" in the compact Dynamic Island when no stage is set. 0 hides it. iPhone only.

Countdown

FieldTypeDefaultInstructions
countdownTonumbernoneThe target time in Unix epoch seconds, as a number (not milliseconds or text). The clock runs on the phone. An alert is sent when the time is reached.
countdownStylestringautohms (00:00:00), days, hours, months, years, or auto. auto shows a running clock (00:00:00) in the last 36 hours, and the largest whole unit before that.
completionTextstringnoneShown in place of the clock once the time is reached, and the title of that alert. Without it, iPhone shows secondaryText and Android shows primaryText.

Action button

To remove the button, send all three fields as "".

FieldTypeDefaultInstructions
actionLabelstringnoneThe button text ("Watch Live"). iPhone shows it on Picture and Versus, on the Lock Screen and the expanded Dynamic Island, not the compact one. Android shows it on any layout when actionURL is set.
actionURLstringnoneThe http or https URL the button opens. Other URLs are dropped.
actionColorHexstringred (Versus), orange (Picture)The button color. iPhone only.

The versus object

Set this inside state when layout is versus.

FieldTypeDefaultInstructions
leftName / rightNamestring""The two sides' names.
leftScore / rightScorestring"0"Scores as text, so "12", "$1,500", and "X" all work. Numbers are turned into text.
leftStatus / rightStatusstring""A small line under each name ("Winner").
activeSidestringnone"left" or "right". When the Dynamic Island is at its smallest, it shows that side's logo.
leftColorHex / rightColorHexstringtext colorEach side's score color. iPhone only.
centerLabelstringnoneSmall text in the middle ("Map").
centerValuestringnoneThe value under it ("Overpass").
leftImageUrl / rightImageUrlstringnoneThe two logos. Transparent PNGs look best.
centerImageUrlstringnoneAn image in the middle (an auction item, a map).
sourceLogoUrlstringnoneThe league or brand logo: the bottom strip on iPhone, the Apple Watch tile, and the Android icon.

The brand object

Optional, set at the top level of the start call. Change it later with POST /api/branding. The site shown under the brand name comes from the page that hosts the launch button, so it is not a brand field.

FieldTypeInstructions
titlestringThe activity's name in the app's list. Falls back to name.
namestringThe brand name ("Acme"). Shown in the app, on the Versus bottom strip, and as the alert title when primaryText is empty. Leave it out to show no source name.
logostringThe logo URL for the app's cover. Falls back to headerIconUrl, then the WebActivity logo.
descriptionstringA short line under the title on the cover. Falls back to secondaryText.
colorstringThe brand color as #RRGGBB. Sets accentColorHex when the state has none.

Ready To Start Building Live Activities Without “Building Them”?

Ready To Start Building Today?

No App Store submission, no native codebase to maintain. A link gets your activity onto your users’ screens, and an easy to use API keeps it live.

Includes: 7,000 Free Pushes per Month

Movistar RidersMovistar RidersTerrorist9
MapOverpass
12HeroicHeroicCounter TerroristCSGOCSGO EsportsWatch Live
8 PM
Doing LaundryComplete This Task By 8:00 PM
Do LaundryClean FloorEat Lunch
Domino'sCooking
912
Movistar RidersMovistar RidersTerrorist9
MapOverpass
12HeroicHeroicCounter TerroristCSGOCSGO EsportsWatch Live
Live
View LiveMoly’s Cat CamUpdated 3 Seconds AgoCat cam
In The Oven NowMat has your order in the oven.Domino's
CookingOn The WayDelivered
Thinking
Researching API EndpointPreparing changes to Foodscout
ThinkingWorkingComplete
Delivery in 30 MinutesMat is racing your way.Domino's
On The WayDelivered
GTA00:00
GTA00:00:00GTA VI
San Francisco ShockHome1
MapMidtown
3
Dallas FuelAwayOverwatch LeagueWatch Live
United 1423Gate B22 · Seat 14C · SFO → JFK
BoardingIn AirArrived
Boarding
Arriving in 6 MinutesMarcus · Toyota CamryToyota Camry
On The WayArrived
6 Min
Movistar RidersMovistar RidersTerrorist9
MapOverpass
12HeroicHeroicCounter TerroristCSGOCSGO EsportsWatch Live
8 PM
Doing LaundryComplete This Task By 8:00 PM
Do LaundryClean FloorEat Lunch
Domino'sCooking
912
Movistar RidersMovistar RidersTerrorist9
MapOverpass
12HeroicHeroicCounter TerroristCSGOCSGO EsportsWatch Live
Live
View LiveMoly’s Cat CamUpdated 3 Seconds AgoCat cam
In The Oven NowMat has your order in the oven.Domino's
CookingOn The WayDelivered
Thinking
Researching API EndpointPreparing changes to Foodscout
ThinkingWorkingComplete
Delivery in 30 MinutesMat is racing your way.Domino's
On The WayDelivered
GTA00:00
GTA00:00:00GTA VI
San Francisco ShockHome1
MapMidtown
3
Dallas FuelAwayOverwatch LeagueWatch Live
United 1423Gate B22 · Seat 14C · SFO → JFK
BoardingIn AirArrived
Boarding
Arriving in 6 MinutesMarcus · Toyota CamryToyota Camry
On The WayArrived
6 Min
Movistar RidersMovistar RidersTerrorist9
MapOverpass
12HeroicHeroicCounter TerroristCSGOCSGO EsportsWatch Live
8 PM
Doing LaundryComplete This Task By 8:00 PM
Do LaundryClean FloorEat Lunch
Domino'sCooking
912
Movistar RidersMovistar RidersTerrorist9
MapOverpass
12HeroicHeroicCounter TerroristCSGOCSGO EsportsWatch Live
Live
View LiveMoly’s Cat CamUpdated 3 Seconds AgoCat cam
In The Oven NowMat has your order in the oven.Domino's
CookingOn The WayDelivered
Thinking
Researching API EndpointPreparing changes to Foodscout
ThinkingWorkingComplete
Delivery in 30 MinutesMat is racing your way.Domino's
On The WayDelivered
GTA00:00
GTA00:00:00GTA VI
San Francisco ShockHome1
MapMidtown
3
Dallas FuelAwayOverwatch LeagueWatch Live
United 1423Gate B22 · Seat 14C · SFO → JFK
BoardingIn AirArrived
Boarding
Arriving in 6 MinutesMarcus · Toyota CamryToyota Camry
On The WayArrived
6 Min