Live Activities for backend workflows and live system state

Show deploys, jobs, automations, AI agent runs, and infrastructure metrics on your lock screen with a simple API call.

Live Activity on iPhone
await activitysmith.liveActivities.start({
content_state: {
title: "API Deployment",
subtitle: "npm i",
number_of_steps: 5,
current_step: 3,
type: "segmented_progress",
},
});

Three Live Activity types

Progress

Best for continuous jobs like uploads, reindexes, syncs, timers, charging sessions, and other work tracked as a percentage or numeric range.

Progress Live Activity on iPhone

Two ways to drive Live Activities

When working with Live Activities via our API, you have two approaches tailored to different needs. First, the stateless mode is the simplest path - simply stream updates using one API call, then end it when the work is done. See the stateless Live Activity stream mode changelog for the release details.

This is ideal if you want minimal complexity, perfect for automated workflows like cron jobs.

In contrast, if you need precise lifecycle control, we have you covered with start, update, and end API methods.

In the following sections, we'll break down how to implement each method so you can choose what fits your use case best.

Let ActivitySmith manage the Live Activity for you

Send the latest state for a stable stream_key. If the Live Activity does not exist yet, ActivitySmith starts it. If it already exists, ActivitySmith updates it.

You do not need to store activity_id or manage the lifecycle yourself. The metrics Live Activities release shows the same pattern applied to runtime stats.

Metrics Live Activity on iPhone
const status = await activitysmith.liveActivities.stream("prod-web-1", {
content_state: {
title: "Server Health",
subtitle: "prod-web-1",
type: "metrics",
metrics: [
{ label: "CPU", value: 9, unit: "%" },
{ label: "MEM", value: 45, unit: "%" },
],
},
});
View Live Activities docs

Manual lifecycle control when you need it

Use start, update, and end when you want to manage a specific Live Activity instance yourself. start returns activity_id, then your backend decides exactly when to update or dismiss it.

Segmented Progress lifecycle

Use this when work moves through discrete steps and the current stage matters more than a raw percentage. The GitHub Action integration is a good example for deployment workflows.

Start

Segmented progress start example
const start = await activitysmith.liveActivities.start({
content_state: {
title: "Nightly database backup",
subtitle: "create snapshot",
number_of_steps: 3,
current_step: 1,
type: "segmented_progress",
color: "yellow",
},
channels: ["devs", "ops"], // Optional
});
const activityId = start.activity_id;

Update

Segmented progress update example
const update = await activitysmith.liveActivities.update({
activity_id: activityId,
content_state: {
title: "Nightly database backup",
subtitle: "upload archive",
current_step: 2,
},
});

End

Segmented progress end example
const end = await activitysmith.liveActivities.end({
activity_id: activityId,
content_state: {
title: "Nightly database backup",
subtitle: "verify restore",
current_step: 3,
auto_dismiss_minutes: 2,
},
});

Progress lifecycle

Use this when progress is continuous and a percentage or numeric range is the clearest signal.

Start

Progress start example
const start = await activitysmith.liveActivities.start({
content_state: {
title: "EV Charging",
subtitle: "Added 30 mi range",
type: "progress",
percentage: 15,
color: "lime",
},
});
const activityId = start.activity_id;

Update

Progress update example
await activitysmith.liveActivities.update({
activity_id: activityId,
content_state: {
title: "EV Charging",
subtitle: "Added 120 mi range",
percentage: 60,
},
});

End

Progress end example
await activitysmith.liveActivities.end({
activity_id: activityId,
content_state: {
title: "EV Charging",
subtitle: "Added 200 mi range",
percentage: 100,
auto_dismiss_minutes: 2,
},
});

Metrics lifecycle

Use this when you want a small set of live stats visible, such as server health, queue pressure, or database load.

Start

Metrics start example
const start = await activitysmith.liveActivities.start({
content_state: {
title: "Server Health",
subtitle: "prod-web-1",
type: "metrics",
metrics: [
{ label: "CPU", value: 9, unit: "%" },
{ label: "MEM", value: 45, unit: "%" },
],
},
});
const activityId = start.activity_id;

Update

Metrics update example
await activitysmith.liveActivities.update({
activity_id: activityId,
content_state: {
title: "Server Health",
subtitle: "prod-web-1",
type: "metrics",
metrics: [
{ label: "CPU", value: 76, unit: "%" },
{ label: "MEM", value: 52, unit: "%" },
],
},
});

End

Metrics end example
await activitysmith.liveActivities.end({
activity_id: activityId,
content_state: {
title: "Server Health",
subtitle: "prod-web-1",
type: "metrics",
metrics: [
{ label: "CPU", value: 7, unit: "%" },
{ label: "MEM", value: 38, unit: "%" },
],
auto_dismiss_minutes: 2,
},
});

Integrate in minutes

Pick your stack and start triggering Live Activities from your backend in a few lines of code.

Frequently asked questions

Can I trigger iOS Live Activities from a backend or cron job?

Yes. ActivitySmith is built for backend-triggered Live Activities, so you can start or stream updates from APIs, cron jobs, CI pipelines, workers, scripts, and automations without building your own iOS app.

Do I need to store activity_id for every Live Activity?

No. If you use stateless stream mode with a stable stream_key, ActivitySmith can manage the Live Activity for you. Store activity_id only when you want direct lifecycle control over start, update, and end calls.

What is the difference between stream_key mode and start/update/end lifecycle control?

Use stream_key mode when you want the simplest integration and do not want to keep state between runs. Use start, update, and end when your backend already has a natural place to store activity_id and you want precise control over each lifecycle step.

Can I use ActivitySmith Live Activities for deployments, CI jobs, and AI agent runs?

Yes. Common use cases include deployments, build pipelines, cron jobs, infrastructure metrics, ETL runs, and AI agent workflows where teams want persistent lock-screen visibility while work is in progress.

Do I need to build my own iOS app to send Live Activities?

No. ActivitySmith provides the iOS app and delivery plumbing. Your backend sends the event data, and ActivitySmith delivers the Live Activity to your team's paired iPhone and iPad devices.

Track backend work and live system state on your team's iOS devices

Give your team one persistent view of deploys, jobs, automations, and metrics. When the work is done, the Live Activity is automatically dismissed. Pair it with push notifications for final outcomes and one-off alerts.