Testing Push Notifications on the iOS Simulator

Create a JSON payload similar to the one below and save it as e.g test.apns

{
    "Simulator Target Bundle": "your app bundle id goes here",
    "aps": {
        "timestamp": 1168364460,
        "event": "update",
        "content-state": {
            "driverName": "Anne Johnson",
            "estimatedDeliveryTime": 1659416400
        },
        "alert": {
            "title": "Delivery Update",
            "body": "Your pizza order will arrive soon.",
            "sound": "example.aiff"
        }
    }
}

Run the simulator, then drag the .apns file over to the iOS simulator. At this point, you should see the Push Notification pop up.

Testing Push Notifications on the iOS Simulator

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s