SlackBot.Cache (slack_bot_ws v0.1.0-rc.2)

View Source

Public API for SlackBot's metadata cache.

The cache keeps lightweight snapshots of the bot's channel membership, known users, and other frequently accessed metadata. The storage backend is pluggable via adapter behaviours so teams can choose ETS, Redis, or their own implementation while keeping the public API stable.

Summary

Types

cache_op()

@type cache_op() ::
  {:join_channel, String.t()}
  | {:leave_channel, String.t()}
  | {:put_user, map(), non_neg_integer()}
  | {:drop_user, String.t()}
  | {:put_metadata, map()}