Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

apns4erl v2 - expecting 410 but getting 200 #169

Open
monkeyfdude opened this issue May 5, 2017 · 0 comments
Open

apns4erl v2 - expecting 410 but getting 200 #169

monkeyfdude opened this issue May 5, 2017 · 0 comments

Comments

@monkeyfdude
Copy link

monkeyfdude commented May 5, 2017

I am trying to use apns4erl v2 to send notifications.

  • I sent 1 notification with app on device.
  • Device received it.
  • I deleted the app on device
  • I send notification again.
  • Expected 410, but received 200

Can you please help?

    Headers = #{ apns_expiration  => <<"0">>
             , apns_priority    => <<"10">>
             , apns_topic       => <<"com.myApp.myApp">>
             },
1> apns:start().
ok
2> apns:connect(cert, my_conn).
{ok,<0.63.0>}
3> DeviceToken = <<"fddbbfcfa5ce04a07d2c053ead7b5466e3bc64362440ddb18b6aerdfb0fc8fd9">>.
<<"fddbbfcfa5ce04a07d2c053ead7b5466e3bc64362440ddb18b6aerdfb0fc8fd9">>
4>  Notification = #{aps => #{alert => <<"you have a message">>}}.
#{aps => #{alert => <<"you have a message">>}}
7> apns:push_notification(my_conn, DeviceToken, Notification).            
{200,
 [{<<"apns-id">>,<<"637EA9C7-9B29-4A1C-D715-2C82C753BA0E">>}],
 no_body}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant