Noizu.Slack.Conversations (Noizu.Slack v0.1.0)

Copy Markdown View Source

Channels, DMs and threads (conversations.*).

Slack params go in opts (e.g. types: ["public_channel", "private_channel"], exclude_archived: true, limit: 200, oldest:, latest:, inclusive:). *_stream helpers walk every page lazily and raise Noizu.Slack.Error on failure.

Summary

Functions

GET conversations.history — channel messages, newest first (one page).

GET conversations.history — streams every message across pages.

GET conversations.info — channel metadata.

POST conversations.join — joins a public channel.

GET conversations.list — lists channels the token can see (one page).

GET conversations.list — streams every channel across pages.

GET conversations.members — member user IDs of a channel (one page).

GET conversations.replies — a thread (parent first) for message ts (one page).

GET conversations.replies — streams every message in the thread across pages.

Functions

history(client, channel, opts \\ [])

GET conversations.history — channel messages, newest first (one page).

history_stream(client, channel, opts \\ [])

@spec history_stream(Noizu.Slack.Client.t(), String.t(), keyword()) :: Enumerable.t()

GET conversations.history — streams every message across pages.

info(client, channel, opts \\ [])

GET conversations.info — channel metadata.

join(client, channel, opts \\ [])

POST conversations.join — joins a public channel.

list(client, opts \\ [])

GET conversations.list — lists channels the token can see (one page).

list_stream(client, opts \\ [])

@spec list_stream(Noizu.Slack.Client.t(), keyword()) :: Enumerable.t()

GET conversations.list — streams every channel across pages.

members(client, channel, opts \\ [])

GET conversations.members — member user IDs of a channel (one page).

replies(client, channel, ts, opts \\ [])

GET conversations.replies — a thread (parent first) for message ts (one page).

replies_stream(client, channel, ts, opts \\ [])

@spec replies_stream(Noizu.Slack.Client.t(), String.t(), String.t(), keyword()) ::
  Enumerable.t()

GET conversations.replies — streams every message in the thread across pages.