12 enum discord_voice_close_opcodes {
13 DISCORD_VOICE_CLOSE_REASON_UNKNOWN_OPCODE = 4001,
14 DISCORD_VOICE_CLOSE_REASON_DECODE_ERROR = 4002,
15 DISCORD_VOICE_CLOSE_REASON_NOT_AUTHENTICATED = 4003,
16 DISCORD_VOICE_CLOSE_REASON_AUTHENTICATION_FAILED = 4004,
17 DISCORD_VOICE_CLOSE_REASON_ALREADY_AUTHENTICATED = 4005,
18 DISCORD_VOICE_CLOSE_REASON_INVALID_SESSION = 4006,
19 DISCORD_VOICE_CLOSE_REASON_SESSION_TIMED_OUT = 4009,
20 DISCORD_VOICE_CLOSE_REASON_SERVER_NOT_FOUND = 4011,
21 DISCORD_VOICE_CLOSE_REASON_UNKNOWN_PROTOCOL = 4012,
22 DISCORD_VOICE_CLOSE_REASON_DISCONNECTED = 4014,
23 DISCORD_VOICE_CLOSE_REASON_SERVER_CRASH = 4015,
24 DISCORD_VOICE_CLOSE_REASON_UNKNOWN_ENCRYPTION_MODE = 4016,
26 extern char* discord_voice_close_opcodes_to_string(
enum discord_voice_close_opcodes);
27 extern enum discord_voice_close_opcodes discord_voice_close_opcodes_from_string(
char*);
28 extern bool discord_voice_close_opcodes_has(
enum discord_voice_close_opcodes,
char*);
31 enum discord_voice_opcodes {
32 DISCORD_VOICE_IDENTIFY = 0,
33 DISCORD_VOICE_SELECT_PROTOCOL = 1,
34 DISCORD_VOICE_READY = 2,
35 DISCORD_VOICE_HEARTBEAT = 3,
36 DISCORD_VOICE_SESSION_DESCRIPTION = 4,
37 DISCORD_VOICE_SPEAKING = 5,
38 DISCORD_VOICE_HEARTBEAT_ACK = 6,
39 DISCORD_VOICE_RESUME = 7,
40 DISCORD_VOICE_HELLO = 8,
41 DISCORD_VOICE_RESUMED = 9,
42 DISCORD_VOICE_CLIENT_DISCONNECT = 13,
43 DISCORD_VOICE_CODEC = 14,
45 extern char* discord_voice_opcodes_to_string(
enum discord_voice_opcodes);
46 extern enum discord_voice_opcodes discord_voice_opcodes_from_string(
char*);
47 extern bool discord_voice_opcodes_has(
enum discord_voice_opcodes,
char*);
50 enum discord_voice_speaking_flags {
51 DISCORD_VOICE_MICROPHONE = 1,
52 DISCORD_VOICE_SOUNDSHARE = 2,
53 DISCORD_VOICE_PRIORITY = 4,
55 extern char* discord_voice_speaking_flags_to_string(
enum discord_voice_speaking_flags);
56 extern enum discord_voice_speaking_flags discord_voice_speaking_flags_from_string(
char*);
57 extern bool discord_voice_speaking_flags_has(
enum discord_voice_speaking_flags,
char*);