Created
February 3, 2016 14:41
-
-
Save kuryaki/7880261b8d3b6e8c68dd to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ### Payload | |
| #### Simple text notification for patient or provider | |
| ``` | |
| { | |
| to: '234', | |
| sender: '987', | |
| text: 'You have a visit scheduled', | |
| channels: ['mail', 'sms'] | |
| } | |
| ``` | |
| **to:** receiver "_id" | |
| **sender:** sender "_id" | |
| **text:** the actual text notification being sent | |
| **channels:** _optional_ array of channels to be used for notification that can be ['ios', 'mail', 'sms', 'socket'] if not set will use all avaliable channels set by [emblem](https://github.com/pagerinc/emblem) | |
| #### Action notification | |
| ``` | |
| { | |
| action: 'visit_scheduled' | |
| payload: { | |
| visitId: 'someVisitId to gather data from' | |
| } | |
| } | |
| ``` | |
| **action:** a string that represents the action that is being fired | |
| **payload:** is the data needed for the action, if the payload dont match the action schema the job is rejected/nacked |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
what about:
Pusher then goes to our user storage, gets the device ids and submits a payload to
broadcast || panela || mailman(in that ORed order)edit: submitted payload should match the described above: