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

Additional payload parameter to support Safari notifications #114

Closed
marcorocca opened this issue Oct 19, 2020 · 2 comments
Closed

Additional payload parameter to support Safari notifications #114

marcorocca opened this issue Oct 19, 2020 · 2 comments
Milestone

Comments

@marcorocca
Copy link
Contributor

First of all congratulations for the great job, your library is simple and effective and I think it's one of the best around written in PHP.

I see that it lacks a simple parameter that will allow it to send even Safari notifications out of the box. Unfortunately Apple's documentation is not updated and many people think it works only with the binary protocol but I have tried your library with a simple fix to make it work.

As you can see here you must prepare a payload with this format:

{
 --
 "aps": {
  "alert": {
   "title": "Flight A998 Now Boarding",
   "body": "Boarding has begun for Flight A998.",
   "action": "View"
  },
  "url-args": ["boarding", "A998"]
 }
}

But pushok doesn't allow to set the url-args parameter that is at the same level of the aps field.

I can send you a pull request with the new parameter and I'll be happy if you can accept it in your project.

@marcorocca marcorocca changed the title Additional payload parameters to support Safari notifications Additional payload parameter to support Safari notifications Oct 19, 2020
@marcorocca
Copy link
Contributor Author

Here the pull request #115

@edamov edamov added this to the 0.11.3 milestone Oct 28, 2020
@edamov
Copy link
Owner

edamov commented Oct 28, 2020

Thank you. It is available in version 0.11.3

@edamov edamov closed this as completed Oct 28, 2020
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

2 participants