Commit 21aaf0c
committed
APNSConfig live_activity_token field
https://firebase.google.com/docs/cloud-messaging/ios/live-activity
With this field and this configuration I am able to send LiveActivity start messages:
```
messaging.Message(
apns=messaging.APNSConfig(
live_activity_token=live_activity_token,
payload=messaging.APNSPayload(
aps=messaging.Aps(
alert=messaging.ApsAlert(
title="Live Activity Started",
body="Your live activity has been started",
),
custom_data = {
"input-push-token": 1,
"event": "start",
"timestamp": int(time.time()),
"content-state": {
"myAttribute": False
},
"attributes-type": "LiveActivityAttributes",
"attributes": {
"myAttribute": False
},
}
),
headers={
"apns-priority": "5",
},
),
),
token=cloud_messaging_token,
)
```1 parent bde3fb0 commit 21aaf0c
2 files changed
+4
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
529 | 529 | | |
530 | 530 | | |
531 | 531 | | |
| 532 | + | |
532 | 533 | | |
533 | 534 | | |
534 | 535 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
332 | 332 | | |
333 | 333 | | |
334 | 334 | | |
| 335 | + | |
335 | 336 | | |
336 | 337 | | |
337 | 338 | | |
338 | 339 | | |
339 | 340 | | |
340 | 341 | | |
341 | 342 | | |
342 | | - | |
| 343 | + | |
343 | 344 | | |
344 | 345 | | |
| 346 | + | |
345 | 347 | | |
346 | 348 | | |
347 | 349 | | |
| |||
0 commit comments