latestOpenAPI 3.1.02026-08-1014497184.0 KB

8b99dca11019

apns
channel/mobile_push

Save an APNs integration

Updates or creates the APNs integration for the project.

put/integrations/apns

Request body

app_idstring required

The default bundle identifier of the application that is configured with this project. It can be overriden on a per token basis, when registering device tokens.

badge'unread' | 'unseen' required

Controls whether the app icon badge counts unread or unseen notifications.

certificatestring required

The APNs certificate in P8 format. Generate it at developer.apple.com with the 'Apple Push Notification service (APNs)' option selected.

key_idstring required

The 10-character Key ID from your Apple Developer account used with the P8 certificate.

payload_version'1' | '2'

Internal payload format version used by MagicBell.

team_idstring required

The Apple Developer Team ID that owns the configured key.

Example request

{
  "app_id": "com.example.myapp",
  "badge": "unread",
  "certificate": "-----BEGIN PRIVATE KEY-----\nMIGTAgEAMBMGByqGSM49AgEGCCqGSM49AwEHBHkwdwIBAQQgHnr4B2P+by++FGu/th0a44E8chJl5v5Vo4gq0YHw6e6gCgYIKoZIzj0DAQehRANCAARCg1MRibnfyeX5mx6+Rtfzzn7UhJP/oaqL4RzSmDuTsd3BTX33cuQ0gWHe20R2m1bLAkI1wrp+zbWOlAOAD7KX\n-----END PRIVATE KEY-----",
  "key_id": "ABCD1234EF",
  "team_id": "ABCD1234EF"
}

Response

OK

app_idstring required

The default bundle identifier of the application that is configured with this project. It can be overriden on a per token basis, when registering device tokens.

badge'unread' | 'unseen' required

Controls whether the app icon badge counts unread or unseen notifications.

certificatestring required

The APNs certificate in P8 format. Generate it at developer.apple.com with the 'Apple Push Notification service (APNs)' option selected.

key_idstring required

The 10-character Key ID from your Apple Developer account used with the P8 certificate.

payload_version'1' | '2'

Internal payload format version used by MagicBell.

team_idstring required

The Apple Developer Team ID that owns the configured key.

Example response

{
  "app_id": "com.example.myapp",
  "badge": "unread",
  "certificate": "-----BEGIN PRIVATE KEY-----\nMIGTAgEAMBMGByqGSM49AgEGCCqGSM49AwEHBHkwdwIBAQQgHnr4B2P+by++FGu/th0a44E8chJl5v5Vo4gq0YHw6e6gCgYIKoZIzj0DAQehRANCAARCg1MRibnfyeX5mx6+Rtfzzn7UhJP/oaqL4RzSmDuTsd3BTX33cuQ0gWHe20R2m1bLAkI1wrp+zbWOlAOAD7KX\n-----END PRIVATE KEY-----",
  "key_id": "ABCD1234EF",
  "team_id": "ABCD1234EF"
}