Skip to content

Commit

Permalink
update doc for new features
Browse files Browse the repository at this point in the history
  • Loading branch information
chemidy committed Jul 9, 2017
1 parent 82a959c commit afe4922
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
10 changes: 9 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,15 @@ This go-firebase-admin SDK supports the following functions :
* not documented

- Cloud Messaging API
* TODO
* SendToDevice : Send Message to individual device
* SendToDevices : Send multicast Message to a list of devices
* SendToDeviceGroup : Send Message to a device group
* SendToTopic : Send Message to a topic
* SendToCondition : Send a message to devices subscribed to the combination of topics
* SubscribeDeviceToTopic : TODO
* SubscribeDevicesToTopic : TODO
* UnSubscribeDeviceFromTopic : TODO
* UnSubscribeDevicesFromTopic : TODO

To-Do List
----------
Expand Down
4 changes: 2 additions & 2 deletions fcm.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ func (fcm *FCM) SendToDevice(registrationToken string, payload Message) (*Respon
return fcm.sendFirebaseRequest(payload)
}

// SendToDevices Send multicast Message to devices
// SendToDevices Send multicast Message to a list of devices
// see https://firebase.google.com/docs/cloud-messaging/admin/send-messages#send_to_individual_devices
func (fcm *FCM) SendToDevices(registrationTokens []string, payload Message) (*Response, error) {

Expand All @@ -58,7 +58,7 @@ func (fcm *FCM) SendToDeviceGroup(notificationKey string, payload Message) (*Res
return fcm.SendToDevice(notificationKey, payload)
}

// SendToTopic TODO NOT IMPLEMENTED
// SendToTopic Send Message to a topic
// see https://firebase.google.com/docs/cloud-messaging/admin/send-messages#send_to_a_topic
func (fcm *FCM) SendToTopic(notificationKey string, payload Message) (*Response, error) {
return fcm.SendToDevice(fmt.Sprint("/topic/", notificationKey), payload)
Expand Down

0 comments on commit afe4922

Please sign in to comment.