EDA.Event.PresenceUpdate (EDA v0.5.0-beta.2)

Copy Markdown View Source

Dispatched when a user's presence is updated. Needs the :guild_presences intent.

A user's custom status (the activity of type 4) is omitted from activities when their profile privacy setting is Friends Only, or Friends & Small Servers Only in a guild of more than 200 members. Its absence therefore does not mean the user has no custom status. The other activity types are not affected by that setting, though Activity Sharing can hide them.

Summary

Functions

Converts a raw Discord payload into this event struct.

Types

t()

@type t() :: %EDA.Event.PresenceUpdate{
  activities: [EDA.Activity.t()] | nil,
  client_status: map() | nil,
  guild_id: String.t() | nil,
  status: String.t() | nil,
  user: EDA.User.t() | nil
}

Functions

from_raw(raw)

@spec from_raw(map()) :: t()

Converts a raw Discord payload into this event struct.