iOS Channel Management API
iOS Live Activities support channel broadcast. Apple returns the channel ID. JPush creates, queries, and deletes channels, and sends channel update/end messages through the Push API.
Existing live_activity_id update/end and remote start (push-to-start) are unchanged. The live_activity.ios length limit is still 3584 bytes.
Channel management and channel push are VIP only. Remote start-and-subscribe, and receiving channel broadcasts on device, require iOS 18 / iPadOS 18 or later. The app must enable Broadcast Capability in Apple Developer; JPush cannot enable it for you. See Apple's Setting up broadcast push notifications.
Endpoint
Channel management:
https://liveactivity-api.jpush.cn
Path prefix /v3/live_activity.
Channel pushes still use the Push API: POST https://api.jpush.cn/v3/push, with the same authentication. See Channel push.
Authentication
Same as the Push API: HTTP Basic, username AppKey, password Master Secret. See REST API overview · Authentication.
Authentication failure is HTTP 401:
- Missing AppKey, or AppKey length is not 24:
error.code7004, messageapp_key doesn't provideorapp_key format is error. - Valid AppKey but wrong Master Secret: HTTP 401 with an empty body.
Non-VIP or expired VIP: create, list, get, and delete return HTTP 403, error.code 7305, message 仅 VIP 应用支持.
Create and delete require iOS Token Authentication (P8). List and get do not.
channel_id is Apple's base64 value and may contain /, +, and =. URL-encode it in the path. JPush does not generate another ID.
Each environment (production and development counted separately) allows at most 10,000 valid channels.
Channel-management APIs are rate-limited. Over the limit: HTTP 429, error.code 2002, message Rate limit exceeded., plus X-Rate-Limit-Limit / X-Rate-Limit-Remaining / X-Rate-Limit-Reset. Blacklisted apps get 403 / 2003. If the app switch is off: 403 / 2004.
Create a channel
POST /v3/live_activity/channels
{
"name": "Volleyball",
"apns_production": false,
"storage_policy": 0
}
| Key | Type | Required | Description |
|---|---|---|---|
| name | string | Optional | At most 64 characters when set. Empty names are allowed. |
| apns_production | boolean | Required | JSON booleans true / false only. Missing, null, strings, or numbers are rejected with HTTP 400 / 7304. |
| storage_policy | int | Optional | 0 do not store; 1 store the latest message. Only these two values. Cannot be changed after create. Omitted value is 0. |
Illegal JSON, or storage_policy not 0 or 1: HTTP 400, error.code 7303, message Invalid storage_policy, must be 0 or 1.
Create is rejected if Broadcast Capability is not enabled.
Success HTTP 200. The channel object includes at least channel_id, name, apns_production, storage_policy, source (jiguang), and status (valid).
{
"channel_id": "dHN0LXNyY2gtY2hubA==",
"name": "Volleyball",
"apns_production": false,
"storage_policy": 0,
"source": "jiguang",
"status": "valid"
}
List
GET /v3/live_activity/channels?apns_production=false
apns_production is required: true / false (also 1 / 0). Query parameters accept 1 / 0; the create body does not.
The success body is an object, not a bare array:
{
"apns_production": false,
"env_state": "enabled",
"detect_time": 1733280000,
"channels": [],
"detected": false,
"invalid_count": 0,
"apple_new_count": 0
}
| Key | Description |
|---|---|
| apns_production | Environment for this query. |
| env_state | enabled, not_enabled, or unknown (not detected yet). |
| detect_time | Last detect time, Unix seconds. 0 if never detected. |
| channels | Channels in this environment. |
| detected | Whether this request actually finished a detect. When false, the two counters stay 0 and must not be read as "no difference from Apple". |
| invalid_count | Invalid channels found in this detect. |
| apple_new_count | Channels newly synced from Apple in this detect. |
| channels[].source | jiguang or apple. |
| channels[].status | valid or invalid. |
| channels[].invalid_since / clean_after | Present only when invalid. clean_after is the expected cleanup time, Unix seconds, default 30 days after invalidation. |
When VIP is valid, list may trigger detect and sync. This is unrelated to the 10,000 limit. Repeated requests in a short window, or a detect that does not finish in this request, return detected false and keep both counters at 0.
Invalid channels stay in the list until deleted or cleaned up. Invalid channels cannot be pushed.
Channels created in Apple Push Console or other tools appear after detect, with source apple, and can be pushed.
Get one
GET /v3/live_activity/channels/{channel_id}?apns_production=false
apns_production is required. This reads JPush local data only and does not call Apple.
Business fields match a list item: channel_id, name, apns_production, storage_policy, source, status. Invalid channels also have invalid_since / clean_after.
Delete
DELETE /v3/live_activity/channels/{channel_id}?apns_production=false
apns_production is required. Valid channels are deleted on Apple first, then locally. Invalid channels are deleted locally only. A valid delete returns 7307 only when Apple reports the feature is not enabled.
Success HTTP 200:
{"channel_id":"dHN0LXNyY2gtY2hubA=="}
After delete, channel update/end is rejected with 频道不存在或不属于该应用环境. A start with input-push-channel still passes when the cache has no row. Apple may still deliver a stored message on that channel.
Error codes
{"error": {"code": 7305, "message": "仅 VIP 应用支持"}}
| HTTP | code | message | When |
|---|---|---|---|
| 401 | 7004 | app_key doesn't provide / app_key format is error |
Missing AppKey, or AppKey length is not 24. Valid AppKey with a wrong Master Secret returns HTTP 401 with an empty body. |
| 400 | 7301 | Invalid channel id | Empty channel ID, or more than 256 bytes after URL decode. Omitting the path segment is not this code: GET is list, DELETE is 404. |
| 400 | 7302 | Invalid channel name | Name longer than 64 characters. |
| 400 | 7303 | Invalid storage_policy, must be 0 or 1 | Create with storage_policy not 0 or 1, or illegal JSON. Both use this message. |
| 400 | 7304 | Invalid apns_production, must be true or false | Create body missing environment, null, or non-boolean; or get/delete/list missing or illegal query parameter. |
| 403 | 7305 | 仅 VIP 应用支持 | Non-VIP or expired VIP. Public GET/POST/DELETE all use this pair. |
| 403 | 7306 | 请先配置 iOS Token Authentication | P8 is not configured. List and get are not blocked. Create and delete (including invalid-channel delete) return 7306 before 7307 / 7309. |
| 403 | 7307 | 请在苹果开发者后台开通 Broadcast Capability | Create when the environment is already not enabled locally, or Apple returns not enabled on a write (create, or delete of a still-valid channel). List still returns HTTP 200 when not enabled. Deleting an invalid channel does not call Apple. |
| 400 | 7308 | 每个环境最多 10,000 个频道,请删除不再使用的频道 | Valid channel count reached the limit. Missing P8 or locally not enabled returns 7306 / 7307 first. |
| 404 | 7309 | 频道不存在 | No such channel for this app and environment. Missing P8 returns 7306 first. |
| 502 | 7311 | 苹果频道管理请求失败,请稍后重试 | Apple manage API failed and it is not "not enabled" (including unreachable manage plane and timeout). |
| 503 | 7315 | 证书服务暂时不可用,请稍后重试。 | Certificate service timeout, non-200, or unparseable response. Missing P8 is 7306. |
| 429 | 2002 | Rate limit exceeded. | Channel-management rate limit, with X-Rate-Limit-* headers. |
| 403 | 2003 | The appKey is in black list. | The app is blacklisted. |
| 403 | 2004 | Need permission to perform this action. | The app's channel-management switch is off. |
Channel push
Same endpoint: POST https://api.jpush.cn/v3/push. Same authentication. The rich-media push API does not support audience.live_activity_channel.
Other live_activity.ios fields follow Live Activity messages.
A development channel cannot be used in production, and the reverse is also true. options.apns_production must match the channel environment; if omitted, the channel is looked up in production.
Update or end by channel
audience may contain only live_activity_channel. Do not combine it with tag, alias, registration_id, or live_activity_id. event must be update or end. It cannot be used to start. platform must include ios and may be the string all. Do not send sms_message at the same time.
options.time_to_live: a no-storage channel only allows 0; omitted is 0. A store-latest channel allows at most 28800 seconds; omitted is 28800. This is an exception to the default 86400. Values outside the global Push API time_to_live range still return 'time_to_live' value is not in valid range.
{
"platform": ["ios"],
"audience": { "live_activity_channel": "dHN0LXNyY2gtY2hubA==" },
"live_activity": {
"ios": {
"event": "update",
"content-state": { "score": "2:1" }
}
},
"options": { "apns_production": false }
}
For end, set event to end. You may send the existing dismissal-date.
On success JPush submits one broadcast to Apple. Target, delivery, and click counts are not provided.
Channel update/end requires the channel to exist locally and be valid. If the environment has never been detected, a locally valid channel can still be pushed.
Remote start and subscribe to a channel
Use the original start audience (broadcast, tag, alias, registration_id, segment). Do not put live_activity_channel in audience. Add optional input-push-channel under live_activity.ios. It is only for event=start.
It is mutually exclusive with input-push-token. JPush does not auto-fill input-push-token when input-push-channel is present.
Start does not require the channel to be registered in JPush. Only a cache row marked invalid is rejected; a missing cache row is allowed. If the environment has never been detected (env_state unknown), start is not rejected as not enabled.
This is still a device push, not a channel broadcast. Target and delivery follow regular device-push statistics. The app must have broadcast capability, on iOS 18 / iPadOS 18 or later. On earlier systems Apple will not start a Live Activity from this payload.
Remote start still uses existing push-to-start (SDK 5.5.0 or later). The server creates the channel ID and gives it to the app. The app subscribes with ActivityKit channels. See the iOS SDK guide and iOS SDK API.
{
"platform": ["ios"],
"audience": "all",
"live_activity": {
"ios": {
"event": "start",
"input-push-channel": "dHN0LXNyY2gtY2hubA==",
"attributes-type": "ScoreAttributes",
"attributes": { "home": "A" },
"content-state": { "score": "0:0" },
"alert": { "title": "Match started", "body": "0:0" }
}
},
"options": { "apns_production": false }
}
Push API errors
Business rejection is HTTP 400, error.code 1003. After a msgid is allocated, the response includes msg_id. Illegal audience format (empty string, or combined with other audience types) is returned before msgid allocation and has no msg_id.
| message | When |
|---|---|
`live_activity_channel` must be a non-empty string |
Not a non-empty string. No msg_id. |
`live_activity_channel` cannot push with other type |
Combined with another audience type. No msg_id. |
| input-push-channel only support start type live_activity push | Update or end request included input-push-channel. |
| input-push-channel can not be used with input-push-token | Start sent both fields. |
| input-push-channel must be a non-empty string | Empty string. |
| 仅 VIP 应用支持 | Non-VIP or expired. This is 400 / 1003, not channel-management 403 / 7305. |
| 该环境的广播能力未开通,无法订阅频道 | Start subscribe when the environment is not enabled. |
| 该频道已失效,无法订阅 | Start subscribe to an invalid channel. An unknown channel (no cache row) is allowed. Never-detected environments do not use the "cannot subscribe" message. |
| live_activity_channel only support update or end type live_activity push | Channel broadcast validation ran, but event is not update or end. |
| 该环境的广播能力未开通,无法按频道推送 | Channel update/end when the environment is not enabled. |
| 频道不存在或不属于该应用环境 | The channel is not in this app environment, or it was deleted. |
| 该频道已失效,不能按频道推送 | Invalid. |
| time_to_live of no-storage channel must be 0 | No-storage channel with a non-zero TTL. |
| time_to_live can not be greater than 28800 | Store-latest channel TTL longer than 8 hours. |
| audience.live_activity_channel only support ios platform | platform does not include ios. |
| sms_message cannot be pushed together with audience.live_activity_channel | Sent together with sms_message. |
| audience.live_activity_channel is not supported by richmedia push api | Rich-media API. If the channel field is rejected first, that message is returned instead. |
| the length N of ios live_activity should be less than 3584 bytes | live_activity.ios longer than 3584 bytes. HTTP 400, error.code 1005, not 1003. Checked only when platform is the string all or the array contains ios. No msg_id. Exactly 3584 is accepted. |
A non-VIP channel push on the Push API is 400 / 1003 仅 VIP 应用支持, not channel-management 403 / 7305.
Notes
- Enable Broadcast Capability in Apple Developer yourself.
- Development channels cannot be used in production, and the reverse is also true.
- After Broadcast Capability is turned off, existing channels in that environment are marked invalid. Channels that no longer exist on Apple are also marked invalid, kept about 30 days, and can be deleted earlier.
- In push records, valid targets, sent, delivered, and delivery rate for channel broadcasts show
--. Apple distributes channel pushes; JPush does not provide target, delivery, or click statistics.