Skip to content

Sending {} as payload not possible #219

Description

@JensSpanier

Because of this check

node-apn/lib/client.js

Lines 576 to 578 in 4912793

if (notification.body !== '{}') {
request.write(notification.body);
}

it is not possible to send {} as payload. But Apple requires this for sending updates for wallets:

Create and send a push notification for each registered device. The notification uses the same certificate and private key that the creator of the pass used to sign the original, the push token registered by the device, and an empty JSON dictionary for the payload.

https://developer.apple.com/documentation/walletpasses/adding-a-web-service-to-update-passes#Send-a-Push-Notification

Is it possible to change this check?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions