Skip to main content

djs_model/gateway/
mod.rs

1//! The [gateway](https://docs.discord.com/developers/events/gateway): opcodes, intents, close
2//! codes, payloads and events.
3//!
4//! This module contains only data types. The connection itself lives in the `djs-gateway`
5//! crate.
6
7mod close_code;
8mod event;
9mod intents;
10mod opcode;
11pub mod payload;
12mod presence;
13mod shard_id;
14
15pub use self::{
16    close_code::CloseCode,
17    event::{DispatchEvent, GatewayEvent, GatewayEventDeserializer},
18    intents::Intents,
19    opcode::OpCode,
20    presence::{
21        Activity, ActivityAssets, ActivityEmoji, ActivityFlags, ActivityParty, ActivitySecrets,
22        ActivityTimestamps, ActivityType, ClientStatus, Presence, PresenceUser, Status,
23        StatusDisplayType,
24    },
25    shard_id::ShardId,
26};
27
28/// The Discord API version targeted by this crate (and by discord.js v14).
29pub const API_VERSION: u8 = 10;