cartel v0.4.0 Cartel.Pusher.Apns

Apple APNS Binary API worker

Summary

Functions

Method to fetch Cartel.Message.Apns.Feedback.t records from feedback service

Sends the message via the specified worker process

Sends a push notification

Functions

feedback(appid)

Specs

feedback(String.t) :: {:ok, Stream.t}

Method to fetch Cartel.Message.Apns.Feedback.t records from feedback service

Returns an Enumerable Stream of Cartel.Message.Apns.Feedback structs.

push(process, message)

Specs

push(pid, Cartel.Message.Apns.t) :: :ok | :error

Sends the message via the specified worker process

send(appid, message, tokens \\ [])

Specs

send(String.t, Cartel.Message.Apns.t, [String.t]) :: {:ok | :error}

Sends a push notification

  • appid: target application identifier present in config.exs
  • message: message struct
  • tokens: list of device tokens
start_link(args)