Skip to content

feat(push): iOS Live Activity support via APNs broadcast channels#2253

Merged
ttypic merged 3 commits into
mainfrom
AIT-794/apns-channel-implementation
Jul 3, 2026
Merged

feat(push): iOS Live Activity support via APNs broadcast channels#2253
ttypic merged 3 commits into
mainfrom
AIT-794/apns-channel-implementation

Conversation

@ttypic

@ttypic ttypic commented Jun 26, 2026

Copy link
Copy Markdown
Collaborator

Spec: ably/specification#500

Summary

Adds Push Admin support for managing iOS Live Activities through APNs broadcast channels. This introduces a two-part API: creating a broadcast channel, then driving the Live Activity lifecycle (start → update → end) over it.

  1. push.admin.createApnsBroadcast(options)

Creates an APNs broadcast channel for an iOS Live Activity. Call once before starting the activity and persist the returned ids for the session.

const { id, apnsChannelId } = await rest.push.admin.createApnsBroadcast({
  messageStoragePolicy: 1, // 1 = cache last update so late-joining devices get current state; 0 = disabled
});
  • New Admin.createApnsBroadcast method (POST /push/apnsBroadcastChannels).
  • New types: PushApnsBroadcastOptions, PushApnsBroadcast.
  1. push.admin.liveActivity lifecycle API

A new LiveActivity class exposed as push.admin.liveActivity, managing the lifecycle of a Live Activity over a broadcast channel:

// Push-to-start to all devices subscribed to the given channels
await rest.push.admin.liveActivity.start({
  recipient: { channels: ['channel-1'], deviceId: 'optional-device' },
  apnsBroadcast: id,
  apns: { /* APNs Live Activity start payload */ },
});

// Update content-state (single push; APNs fans out to subscribers)
await rest.push.admin.liveActivity.update({
  apnsBroadcast: id,
  apns: { /* APNs update payload */ },
  headers: { 'apns-priority': 5 },
});

// End the activity on all devices and clean up the channel
await rest.push.admin.liveActivity.end({
  apnsBroadcast: id,
  apns: { /* APNs end payload */ },
});
  • start → POST /push/apnsBroadcastChannels/{id}/start (supports targeting all subscribed channels, optionally restricted to a single deviceId).
  • update → POST /push/apnsBroadcastChannels/{id}/broadcast (optional apns-priority / apns-expiration headers).
  • end → POST /push/apnsBroadcastChannels/{id}/end; the broadcast id is no longer valid afterwards.
  • APNs payloads are passed through as-is.
  • New types: PushLiveActivity, PushLiveActivityStartParams, PushLiveActivityUpdateParams, PushLiveActivityEndParams.

Summary by CodeRabbit

Summary by CodeRabbit

  • New Features
    • Added iOS Live Activity support via APNs broadcast channels.
    • Introduced APIs to create APNs broadcast channels and manage Live Activities (start, update, end), including support for APNs payload and optional request headers.
  • Tests
    • Added REST unit tests for APNs broadcast channel creation and Live Activity start/update/end requests, validating request structure and HTTP error handling.

@coderabbitai

coderabbitai Bot commented Jun 26, 2026

Copy link
Copy Markdown

Review Change Stack

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: ae7c39e3-4e5d-4e3d-8bff-b5817d852b65

📥 Commits

Reviewing files that changed from the base of the PR and between a1691fb and eaf29d6.

📒 Files selected for processing (4)
  • ably.d.ts
  • src/common/lib/client/push.ts
  • test/uts/rest/unit/push/push_admin_apns_broadcast.test.ts
  • test/uts/rest/unit/push/push_admin_live_activity.test.ts
🚧 Files skipped from review as they are similar to previous changes (4)
  • test/uts/rest/unit/push/push_admin_apns_broadcast.test.ts
  • test/uts/rest/unit/push/push_admin_live_activity.test.ts
  • ably.d.ts
  • src/common/lib/client/push.ts

Walkthrough

The PR adds APNs broadcast channel support to the push admin API, with new type declarations, runtime request methods, and tests for creating broadcast channels and managing Live Activity start, update, and end flows.

Changes

APNs Broadcast Live Activity Support

Layer / File(s) Summary
Public contracts
ably.d.ts
PushAdmin gains APNs broadcast creation and live activity methods, along with new request and result interfaces for those operations.
Runtime flow
src/common/lib/client/push.ts
Admin initializes liveActivity, adds APNs broadcast channel creation, and routes Live Activity start, update, and end requests through the push API helper.
Broadcast tests
test/uts/rest/unit/push/push_admin_apns_broadcast.test.ts
Tests cover APNs broadcast channel creation, request body fields, response mapping, authorization headers, and server error propagation.
Live activity tests
test/uts/rest/unit/push/push_admin_live_activity.test.ts
Tests cover Live Activity start, update, and end requests, including request bodies, recipient fields, headers, URL encoding, and error propagation.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Poem

I’m a rabbit with twitchy ears,
Hopping through broadcasts bright and neat.
Start, update, end — wee Live Activities dance,
With APNs beats beneath my feet.
Thump, thump — the carrot code is sweet 🐇

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly matches the main change: adding iOS Live Activity support through APNs broadcast channels.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch AIT-794/apns-channel-implementation

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@ttypic ttypic marked this pull request as draft June 26, 2026 13:02
@github-actions github-actions Bot temporarily deployed to staging/pull/2253/bundle-report June 26, 2026 13:02 Inactive

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@ably.d.ts`:
- Line 3710: Remove the blank lines between JSDoc tags in the affected
declarations so the docblocks no longer trigger the “Expected no lines between
tags” lint error. Update the JSDoc blocks around the referenced declaration
group in ably.d.ts, and apply the same cleanup consistently to the other
affected blocks mentioned in the comment.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 269deb54-60c8-48e3-8653-f7fe79b347fe

📥 Commits

Reviewing files that changed from the base of the PR and between 13bd25d and da0431f.

📒 Files selected for processing (2)
  • ably.d.ts
  • src/common/lib/client/push.ts

Comment thread ably.d.ts
@ttypic ttypic marked this pull request as ready for review June 29, 2026 10:14
@ttypic ttypic requested a review from VeskeR June 29, 2026 10:14
@ttypic ttypic force-pushed the AIT-794/apns-channel-implementation branch from da0431f to 0a4779d Compare July 1, 2026 09:14
@github-actions github-actions Bot temporarily deployed to staging/pull/2253/bundle-report July 1, 2026 09:15 Inactive
@github-actions github-actions Bot temporarily deployed to staging/pull/2253/typedoc July 1, 2026 09:15 Inactive

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (2)
src/common/lib/client/push.ts (2)

117-144: 🗄️ Data Integrity & Integration | 🟡 Minor | ⚡ Quick win

Propagate pushFullWait to APNs broadcast/live-activity requests createApnsBroadcast and LiveActivity._post should add fullWait: 'true' to params so these endpoints behave like publish and the other push-mutating calls; otherwise pushFullWait is ignored here.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@src/common/lib/client/push.ts` around lines 117 - 144, The APNs broadcast and
live-activity push paths are missing the full-wait request flag, so
`pushFullWait` is ignored in these mutating calls. Update `createApnsBroadcast`
and `LiveActivity._post` in the push client code to include `fullWait: 'true'`
in their request `params`, matching the behavior used by `publish` and the other
push mutation methods.

302-326: 🗄️ Data Integrity & Integration | 🟠 Major | ⚡ Quick win

Restore fullWait forwarding in DeviceRegistrations.remove. This is the only push-delete path that drops client.options.pushFullWait, so callers lose the synchronous-delete behavior other admin methods still provide.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@src/common/lib/client/push.ts` around lines 302 - 326, Restore forwarding of
client.options.pushFullWait in DeviceRegistrations.remove so the push delete
call matches the other admin delete paths. Update the remove method in
DeviceRegistrations to pass the fullWait flag through the Resource['delete']
invocation, using the existing client.options.pushFullWait value alongside the
current headers, params, and deviceId handling.
🧹 Nitpick comments (2)
src/common/lib/client/push.ts (2)

154-172: 🎯 Functional Correctness | 🔵 Trivial | 💤 Low value

No validation that recipient has a target.

start doesn't validate that at least one of recipient.channels or recipient.deviceId is provided; if a caller supplies neither, the request silently posts with no channels/deviceId field, likely producing an unhelpful server-side error rather than a clear client-side one.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@src/common/lib/client/push.ts` around lines 154 - 172, The start method in
push client does not validate that recipient has a delivery target before
calling _post. Add an explicit check in start(params) to require at least one of
recipient.channels or recipient.deviceId, and fail fast with a clear client-side
error if neither is present. Keep the validation close to the existing recipient
destructuring/body construction so the behavior is easy to find and maintain.

117-144: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Inline request/response types duplicate the public contracts.

createApnsBroadcast's options/return shape and LiveActivity.start/update/end parameter shapes are hand-written inline object types here, while the PR objectives state named types (PushApnsBroadcastOptions, PushApnsBroadcast, PushLiveActivity start/update/end params) are added to ably.d.ts. Duplicating the shape in two places risks type drift as the public API evolves (e.g., an added optional field in ably.d.ts wouldn't be reflected here without a corresponding edit).

Consider importing and using the canonical types from the public contracts module instead of re-declaring them inline.

Also applies to: 154-190

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@src/common/lib/client/push.ts` around lines 117 - 144, Inline
request/response types in createApnsBroadcast and LiveActivity.start/update/end
are duplicating the public API contracts and can drift from the named types
added to ably.d.ts. Update these methods to use the canonical exported types
(PushApnsBroadcastOptions, PushApnsBroadcast, and PushLiveActivity
start/update/end param types) instead of re-declaring object shapes inline. Keep
the method logic unchanged; only replace the local type annotations so the
client stays aligned with the public contract definitions.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Outside diff comments:
In `@src/common/lib/client/push.ts`:
- Around line 117-144: The APNs broadcast and live-activity push paths are
missing the full-wait request flag, so `pushFullWait` is ignored in these
mutating calls. Update `createApnsBroadcast` and `LiveActivity._post` in the
push client code to include `fullWait: 'true'` in their request `params`,
matching the behavior used by `publish` and the other push mutation methods.
- Around line 302-326: Restore forwarding of client.options.pushFullWait in
DeviceRegistrations.remove so the push delete call matches the other admin
delete paths. Update the remove method in DeviceRegistrations to pass the
fullWait flag through the Resource['delete'] invocation, using the existing
client.options.pushFullWait value alongside the current headers, params, and
deviceId handling.

---

Nitpick comments:
In `@src/common/lib/client/push.ts`:
- Around line 154-172: The start method in push client does not validate that
recipient has a delivery target before calling _post. Add an explicit check in
start(params) to require at least one of recipient.channels or
recipient.deviceId, and fail fast with a clear client-side error if neither is
present. Keep the validation close to the existing recipient destructuring/body
construction so the behavior is easy to find and maintain.
- Around line 117-144: Inline request/response types in createApnsBroadcast and
LiveActivity.start/update/end are duplicating the public API contracts and can
drift from the named types added to ably.d.ts. Update these methods to use the
canonical exported types (PushApnsBroadcastOptions, PushApnsBroadcast, and
PushLiveActivity start/update/end param types) instead of re-declaring object
shapes inline. Keep the method logic unchanged; only replace the local type
annotations so the client stays aligned with the public contract definitions.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 992de5b7-2bea-429b-943f-d0e318328f2d

📥 Commits

Reviewing files that changed from the base of the PR and between da0431f and 0a4779d.

📒 Files selected for processing (4)
  • ably.d.ts
  • src/common/lib/client/push.ts
  • test/uts/rest/unit/push/push_admin_apns_broadcast.test.ts
  • test/uts/rest/unit/push/push_admin_live_activity.test.ts
🚧 Files skipped from review as they are similar to previous changes (1)
  • ably.d.ts

Comment thread src/common/lib/client/push.ts
Comment thread ably.d.ts Outdated
/**
* The targeted recipients of the push-to-start notification.
*/
recipient: {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

RSH1e1 describes this as

is either a list of channels or a single deviceId

Can we improve the type by having a union between { channels } | { deviceId } so at least one field is required?

@VeskeR VeskeR Jul 2, 2026

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and possible have an explicit check and throw an error in the .start() method?
and then a corresponding test for possible combinations

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added error, narrowed down type, but it's not for UTS, it won't matter for statically-typed languages

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

but it's not for UTS, it won't matter for statically-typed languages

Huh, interesting. I see why we wouldn't want it to be in the UTS, but not including the tests in languages where it actually helps seems wrong

Comment thread ably.d.ts Outdated
Comment thread ably.d.ts
/**
* Set to `1` to cache the last update payload so late-joining devices receive the current content state immediately on subscription. Set to `0` to disable caching.
*/
messageStoragePolicy: 0 | 1;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we have an actual string enum for this in public API types? and then decode to the integer when sending to the server

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

discussed earlier, when doing DR, don't remember why, but agreed to use numbers, I'll ask why, but let's not block on this.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

uhh, sure. A bit uncomfortable for me to approve as we don't have raw integers anywhere else in the codebase, it's always a string enum in public types.

@ttypic ttypic requested a review from VeskeR July 2, 2026 16:31
@ttypic ttypic force-pushed the AIT-794/apns-channel-implementation branch from 0a4779d to 3c1eadf Compare July 3, 2026 11:38
@github-actions github-actions Bot temporarily deployed to staging/pull/2253/features July 3, 2026 11:38 Inactive
@github-actions github-actions Bot temporarily deployed to staging/pull/2253/bundle-report July 3, 2026 11:38 Inactive
@github-actions github-actions Bot temporarily deployed to staging/pull/2253/typedoc July 3, 2026 11:39 Inactive

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (2)
src/common/lib/client/push.ts (2)

117-144: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Reuse declared public types instead of inline shapes.

The public contracts layer already declares PushApnsBroadcastOptions/PushApnsBroadcast types for this operation. This method redefines the option and return shapes inline ({ messageStoragePolicy: 0 | 1 }, { id: string; apnsChannelId: string }), so a future change to the public .d.ts contract won't be enforced by the compiler here, risking silent drift between the API surface and its implementation.

♻️ Suggested type reuse
-  async createApnsBroadcast(options: { messageStoragePolicy: 0 | 1 }): Promise<{ id: string; apnsChannelId: string }> {
+  async createApnsBroadcast(options: API.PushApnsBroadcastOptions): Promise<API.PushApnsBroadcast> {

Separately, publish() mixes client.options.pushFullWait into params (Line 111) but this method does not. Please confirm this omission is intentional for the broadcast-channel-creation endpoint (the prior discussion on fullWait removal was specifically about Live Activity endpoints, not createApnsBroadcast).

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@src/common/lib/client/push.ts` around lines 117 - 144, The
createApnsBroadcast method in PushClient is using inline request/response shapes
instead of the જાહેર contract types, so update its signature and related locals
to reuse PushApnsBroadcastOptions and PushApnsBroadcast from the public types
layer. Also review the params setup in createApnsBroadcast to confirm whether
pushFullWait should be omitted or explicitly added for this endpoint, since
publish() handles it differently and the omission may need to match the intended
API contract.

154-201: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Consolidate duplicated request-body construction and reuse declared param types.

start, update, and end each redeclare the same inline { apnsBroadcast, apns, headers? } shape and repeat the if (headers) body.headers = headers pattern. Extracting a small shared helper would reduce duplication as more Live Activity actions are added. Additionally, per the PR's public contracts layer, dedicated parameter types (PushLiveActivityStart..., etc.) already exist — using them here instead of inline object types would keep the implementation and the .d.ts contract in sync.

♻️ Suggested consolidation
+  private buildActivityBody(apns: any, headers?: Record<string, string>): Record<string, any> {
+    const body: Record<string, any> = { apns };
+    if (headers) {
+      body.headers = headers;
+    }
+    return body;
+  }
+
   async update(params: { apnsBroadcast: string; apns: any; headers?: Record<string, string> }): Promise<void> {
     const { apnsBroadcast, apns, headers } = params;
-    const body: Record<string, any> = { apns };
-    if (headers) {
-      body.headers = headers;
-    }
+    const body = this.buildActivityBody(apns, headers);
     await this._post(apnsBroadcast, 'broadcast', body);
   }

   async end(params: { apnsBroadcast: string; apns: any; headers?: Record<string, string> }): Promise<void> {
     const { apnsBroadcast, apns, headers } = params;
-    const body: Record<string, any> = { apns };
-    if (headers) {
-      body.headers = headers;
-    }
+    const body = this.buildActivityBody(apns, headers);
     await this._post(apnsBroadcast, 'end', body);
   }

Also worth confirming: does end() genuinely require an apns payload, or could it be a bodiless/minimal request in some cases? The provided test snippets only cover start/update; please verify against the Live Activity test file for end.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@src/common/lib/client/push.ts` around lines 154 - 201, The Live Activity
methods in PushClient repeat the same request-body assembly and use inline
parameter shapes, so consolidate the shared body/header construction into a
small helper and switch start, update, and end to the existing dedicated
parameter types instead of redeclaring `{ apnsBroadcast, apns, headers? }`
inline. Keep the public contract aligned by reusing the declared types already
available for the Live Activity actions, and verify whether end in PushClient
really needs an apns payload or should send a minimal/bodiless request based on
the Live Activity tests.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Nitpick comments:
In `@src/common/lib/client/push.ts`:
- Around line 117-144: The createApnsBroadcast method in PushClient is using
inline request/response shapes instead of the જાહેર contract types, so update
its signature and related locals to reuse PushApnsBroadcastOptions and
PushApnsBroadcast from the public types layer. Also review the params setup in
createApnsBroadcast to confirm whether pushFullWait should be omitted or
explicitly added for this endpoint, since publish() handles it differently and
the omission may need to match the intended API contract.
- Around line 154-201: The Live Activity methods in PushClient repeat the same
request-body assembly and use inline parameter shapes, so consolidate the shared
body/header construction into a small helper and switch start, update, and end
to the existing dedicated parameter types instead of redeclaring `{
apnsBroadcast, apns, headers? }` inline. Keep the public contract aligned by
reusing the declared types already available for the Live Activity actions, and
verify whether end in PushClient really needs an apns payload or should send a
minimal/bodiless request based on the Live Activity tests.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 97e68df2-bc7b-4317-b6b5-e3a7dfda5658

📥 Commits

Reviewing files that changed from the base of the PR and between 0a4779d and 3c1eadf.

📒 Files selected for processing (4)
  • ably.d.ts
  • src/common/lib/client/push.ts
  • test/uts/rest/unit/push/push_admin_apns_broadcast.test.ts
  • test/uts/rest/unit/push/push_admin_live_activity.test.ts
🚧 Files skipped from review as they are similar to previous changes (3)
  • test/uts/rest/unit/push/push_admin_apns_broadcast.test.ts
  • test/uts/rest/unit/push/push_admin_live_activity.test.ts
  • ably.d.ts

Comment thread ably.d.ts Outdated
/**
* Restrict the push-to-start notification to a single device. Provide either `channels` or `deviceId`.
*/
deviceId?: string;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we make channels and deviceId not optional here?

@VeskeR VeskeR left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving, two small oustanding points:

  • make non optional channels and deviceId
  • As discussed on standup, messageStoragePolicy is Apple's related field, so keeping it as an integer would be fine as this is what Apple uses. We agreed to at least include the link to the Apple's docs for this. Potentially we may decide to change to the enum if the team agrees it will be of benefit.

@github-actions github-actions Bot temporarily deployed to staging/pull/2253/features July 3, 2026 17:01 Inactive
@github-actions github-actions Bot temporarily deployed to staging/pull/2253/bundle-report July 3, 2026 17:01 Inactive
@github-actions github-actions Bot temporarily deployed to staging/pull/2253/typedoc July 3, 2026 17:01 Inactive
ttypic added 3 commits July 3, 2026 18:07
- Introduced `createApnsBroadcast` function in the Push client to support APNs broadcast channels.
- Added support for defining `messageStoragePolicy` options.
- Updated `ably.d.ts` to include types for `PushApnsBroadcastOptions` and `PushApnsBroadcast`.
- Introduced `LiveActivity` class to manage the lifecycle of iOS Live Activities (start, update, end) via APNs broadcast channels.
- Updated `ably.d.ts` with types for `PushLiveActivity` and associated parameters.
- Updated `PushChannelOptions` to set `channels` and `deviceId` as mandatory fields.
- Added a reference link for `messageStoragePolicy` in `PushApnsBroadcastOptions`.
@ttypic ttypic merged commit 442ec1c into main Jul 3, 2026
12 of 17 checks passed
@ttypic ttypic deleted the AIT-794/apns-channel-implementation branch July 3, 2026 17:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants