├ 08

rich notifications

edgepush forwards the full APNs and FCM header surface so you can ship features Expo Push Service can't. The fields below are all optional and additive, the basic { to, title, body } still works.

await client.send({
  to: deviceToken,
  title: "New order #4271",
  body: "2x flat white, table 3",

  // rich notification image
  image: "https://cdn.acme.app/o/4271.jpg",
  mutableContent: true,  // required for the iOS NSE pattern

  // collapse-id: identical keys replace each other on the device
  collapseId: "order-4271",

  // absolute expiration timestamp
  expirationAt: Math.floor(Date.now() / 1000) + 600,

  // explicit apns push type (default: "alert")
  pushType: "alert",
});

For iOS rich notifications you also need a Notification Service Extension target in your app. Apple's Modifying content in newly delivered notifications walks through the NSE setup.