Skip to content

armgit / macro

Public Imported from GitHub
0

Macro is a unified workspace for teams: email, chat, docs, tasks, agents, calls, and CRM — @-linked together with shared AI memory.

fix(ios calls): do not replay dead calls (#5617)

Peter Chinmanfc737f0d4df7
diff --git a/crates/notification/src/outbound/mobile.rs b/crates/notification/src/outbound/mobile.rs
index 5c13876d49..10f4df24f0 100644
--- a/crates/notification/src/outbound/mobile.rs
+++ b/crates/notification/src/outbound/mobile.rs
@@ -190,8 +190,22 @@ fn build_voip_sns_attributes(voip_bundle_id: &str) -> HashMap<String, MessageAtt
.build()
.expect("valid attribute"),
),
+ // TTL is the one SNS attribute that is named per platform application
+ // (unlike TOPIC/PUSH_TYPE/PRIORITY, which are shared across APNs
+ // platforms). `AWS.SNS.MOBILE.APNS.TTL` is silently ignored on
+ // APNS_VOIP endpoints, leaving the SNS default of 4 weeks — APNs then
+ // stores the push while the device is unreachable and replays a dead
+ // call ring when it reconnects. TTL 0 means "deliver now or drop".
(
- "AWS.SNS.MOBILE.APNS.TTL".to_string(),
+ "AWS.SNS.MOBILE.APNS_VOIP.TTL".to_string(),
+ MessageAttributeValue::builder()
+ .data_type("String")
+ .string_value("0")
+ .build()
+ .expect("valid attribute"),
+ ),
+ (
+ "AWS.SNS.MOBILE.APNS_VOIP_SANDBOX.TTL".to_string(),
MessageAttributeValue::builder()
.data_type("String")
.string_value("0")