Is a simple wrapper around Firebase Cloud Messaging that uses HTTPoison.
config :exfcm,
fcm_url: "fcmHTTPRequestEndpoint"
server_key: "yourKeyFromConsole"{:ok , result } = Message.put_data("sample","true")
|> Message.put_notification("Title","Github")
|> Message.put_notification("body","is_awesome")
|> Message.target_topic("aTopic")
|> Message.send{:ok , result } = Message.put_data("sample", "true")
|> Message.put_notification("title","Github")
|> Message.put_notification("body","is_awesome")
|> Message.target_device("deviceToken")
|> Message.sendIf available in Hex, the package can be installed as:
- Add
exfcmto your list of dependencies inmix.exs:
```elixir
def deps do
[{:exfcm, "~> 0.1.0"}]
end
```
- Ensure
exfcmis started before your application:
```elixir
def application do
[applications: [:exfcm]]
end
```
- Add custom filters
- Add suport for additional params on notification