Stampede.Channels.Message (stampede v1.4.0)

Copy Markdown View Source

A message of the Phoenix Channels protocol, as a Stampede.Channels.Serializer encodes and decodes it.

The payload is decoded JSON, or {:binary, data} for a binary payload. Replies have the "phx_reply" event, and a payload with the "status" and the "response".

Summary

Types

t()

@type t() :: %Stampede.Channels.Message{
  event: String.t(),
  join_ref: String.t() | nil,
  payload: term(),
  ref: String.t() | nil,
  topic: String.t()
}