Archived
1
0
Fork 0
This repository has been archived on 2024-05-21. You can view files and clone it, but cannot push or open issues or pull requests.
maki/Maki/Gateway/GatewayCloseCode.cs

64 lines
1.8 KiB
C#
Raw Permalink Normal View History

2017-05-14 12:02:51 +00:00
namespace Maki.Gateway
{
/// <summary>
/// Extended WebSocket close codes used by Discord's Gateway
/// </summary>
enum GatewayCloseCode
{
/// <summary>
/// We're not sure what went wrong. Try reconnecting?
/// </summary>
Unknown = 4000,
/// <summary>
/// You sent an invalid Gateway OP Code. Don't do that!
/// </summary>
UnknownOPCode = 4001,
/// <summary>
/// You sent an invalid payload to us. Don't do that!
/// </summary>
DecodeError = 4002,
/// <summary>
/// You sent us a payload prior to identifying.
/// </summary>
NotAuthenticated = 4003,
/// <summary>
/// The account token sent with your identify payload is incorrect.
/// </summary>
AuthenticationFailed = 4004,
/// <summary>
/// You sent more than one identify payload. Don't do that!
/// </summary>
AlreadyAuthenticated = 4005,
/// <summary>
/// The sequence sent when resuming the session was invalid. Reconnect and start a new session.
/// </summary>
InvalidSequence = 4007,
/// <summary>
/// Woah nelly! You're sending payloads to us too quickly. Slow it down!
/// </summary>
RateLimited = 4008,
/// <summary>
/// Your session timed out. Reconnect and start a new one.
/// </summary>
SessionTimeout = 4009,
/// <summary>
/// You sent us an invalid shard when identifying.
/// </summary>
InvalidShard = 4010,
/// <summary>
/// The session would have handled too many guilds - you are required to shard your connection in order to connect.
/// </summary>
ShardingRequired = 4011,
}
}