Get Started
Integrate Channel Providers

Apple Push Notification Service (APNs) Integration

Connect Apple Push Notification service (APNs) to deliver native iOS push notifications. HubNest uses Apple .p8 signing key authentication (Token-Based Auth) — the modern, recommended approach over certificate-based auth.

1

1. Create APNs Signing Key (.p8)

Go to Apple Developer Console (developer.apple.com) → Certificates, Identifiers & Profiles → Keys → click the + button to create a new key. Enable "Apple Push Notifications service (APNs)" capability. Click Continue → Register → Download. Save the downloaded file (AuthKey_XXXXXXXXXX.p8) — you can only download it once.

One-time download
The .p8 key file can only be downloaded once. Store it securely. If lost, you must revoke and create a new key.
2

2. Note Key ID, Team ID & Bundle ID

Before leaving Apple Developer Console, note down these three identifiers:

APNs Credential Format
HubNest validates that the pasted Credentials contain -----BEGIN PRIVATE KEY----- and -----END PRIVATE KEY----- PEM blocks. The Key ID, Team ID, and Bundle ID are stored as separate fields in the provider configuration.
  • Key ID: 10-character alphanumeric ID shown on the key detail page (also in the .p8 filename, e.g. AuthKey_ABCD1234EF.p8 → Key ID is ABCD1234EF).
  • Team ID: 10-character alphanumeric ID from your Apple Developer Account → Membership → Team ID.
  • Bundle ID: Your app bundle identifier from Identifiers section (e.g. com.yourcompany.yourapp).
3

3. Configure APNs in HubNest Dashboard

Go to Developer → Channels → Push → Add Provider → select APNs. Fill in:

  • Credentials: Paste the full contents of your AuthKey_XXXXXXXXXX.p8 file — must start with -----BEGIN PRIVATE KEY----- and end with -----END PRIVATE KEY-----.
  • Key ID: 10-character Key ID (from .p8 filename or Apple Developer Console).
  • Team ID: 10-character Apple Developer Team ID.
  • Bundle ID: Your iOS app bundle identifier (e.g. com.yourcompany.app).
4

4. Test Connection & Save

Click "Test Connection" — the backend validates that the pasted text contains valid -----BEGIN PRIVATE KEY----- and -----END PRIVATE KEY----- PEM structure. On success, click Save — the .p8 key is AES-256 encrypted and stored. Provider turns CONNECTED.

Structure validation only
APNs test checks PEM key structure (not a live Apple API call). Full validation occurs on the first actual push dispatch.
5

5. Create Subscriber & Register iOS Device Token

First create a subscriber (POST /developer/subscribers), then register the iOS APNs device token for that subscriber (POST /developer/subscribers/{id}/devices with platform: "IOS"). Get the iOS device token from your Swift app using UNUserNotificationCenter.

6

6. Send iOS Push Notification

From the Push dashboard, click "Send Individual". Enter the APNs device token as recipient (or subscriber ID). Enter notification body. Click Send. Or call the Notification API with channel: "PUSH" and recipient = the iOS device token string.

7

7. Launch Bulk Push Campaign

Go to Channels → Push → Bulk Campaigns → Create Campaign. Upload CSV with APNs tokens or subscriber IDs → Enter notification body → Launch via Kafka queue. All active device tokens for each subscriber are dispatched via Firebase Multicast (Android) or APNs (iOS).

Was this guide helpful?