LemonChannels.Telegram.Delivery (lemon_channels v0.1.0)

View Source

Telegram delivery helpers backed only by LemonChannels.Outbox.

Summary

Types

chat_id()

@type chat_id() :: integer() | binary()

enqueue_opt()

@type enqueue_opt() ::
  {:account_id, binary()}
  | {:thread_id, integer() | binary()}
  | {:topic_id, integer() | binary()}
  | {:reply_to_message_id, integer() | binary()}
  | {:reply_to, integer() | binary()}
  | {:reply_markup, map()}
  | {:priority, integer()}
  | {:key, term()}
  | {:peer_kind, :dm | :group | :channel}
  | {:idempotency_key, binary()}
  | {:meta, map()}
  | {:notify, {pid(), reference()} | {pid(), reference(), atom()}}
  | {:notify_pid, pid()}
  | {:notify_ref, reference()}
  | {:notify_tag, atom()}

Functions

enqueue_send(chat_id, text, opts \\ [])

@spec enqueue_send(chat_id(), binary(), [enqueue_opt()]) :: :ok | {:error, term()}