refactor progress
This commit is contained in:
23
fluxer_docs/gateway/close_codes.mdx
Normal file
23
fluxer_docs/gateway/close_codes.mdx
Normal file
@@ -0,0 +1,23 @@
|
||||
---
|
||||
title: 'Close codes'
|
||||
description: 'WebSocket close codes used by the Fluxer gateway.'
|
||||
---
|
||||
|
||||
When the gateway closes a connection, it sends a close code indicating why. Some close codes are recoverable (the client should reconnect), while others are not.
|
||||
|
||||
## Close code reference
|
||||
|
||||
| Code | Name | Description | Reconnect |
|
||||
|------|------|-------------|----------|
|
||||
| `4000` | `UNKNOWN_ERROR` | Unknown error occurred | Yes |
|
||||
| `4001` | `UNKNOWN_OPCODE` | Sent an invalid gateway opcode | Yes |
|
||||
| `4002` | `DECODE_ERROR` | Sent an invalid payload | Yes |
|
||||
| `4003` | `NOT_AUTHENTICATED` | Sent a payload before identifying | Yes |
|
||||
| `4004` | `AUTHENTICATION_FAILED` | Account token is invalid | No |
|
||||
| `4005` | `ALREADY_AUTHENTICATED` | Sent more than one identify payload | Yes |
|
||||
| `4007` | `INVALID_SEQ` | Sent an invalid sequence when resuming | Yes |
|
||||
| `4008` | `RATE_LIMITED` | Sending payloads too quickly | Yes |
|
||||
| `4009` | `SESSION_TIMEOUT` | Session timed out; reconnect and start a new one | Yes |
|
||||
| `4010` | `INVALID_SHARD` | Sent an invalid shard when identifying | No |
|
||||
| `4011` | `SHARDING_REQUIRED` | Session would have handled too many guilds; sharding is required | No |
|
||||
| `4012` | `INVALID_API_VERSION` | Sent an invalid gateway version | No |
|
||||
6
fluxer_docs/gateway/connection_lifecycle.mdx
Normal file
6
fluxer_docs/gateway/connection_lifecycle.mdx
Normal file
@@ -0,0 +1,6 @@
|
||||
---
|
||||
title: 'Connection lifecycle'
|
||||
description: 'Connect, identify, stay connected, and recover from disconnects.'
|
||||
---
|
||||
|
||||
TBD
|
||||
1328
fluxer_docs/gateway/events.mdx
Normal file
1328
fluxer_docs/gateway/events.mdx
Normal file
File diff suppressed because it is too large
Load Diff
25
fluxer_docs/gateway/opcodes.mdx
Normal file
25
fluxer_docs/gateway/opcodes.mdx
Normal file
@@ -0,0 +1,25 @@
|
||||
---
|
||||
title: 'Opcodes'
|
||||
description: 'Gateway opcodes used for communication between client and server.'
|
||||
---
|
||||
|
||||
Gateway opcodes indicate the type of payload being sent or received. Clients send and receive different opcodes depending on their role in the connection lifecycle.
|
||||
|
||||
## Opcode reference
|
||||
|
||||
| Opcode | Name | Description | Client Action |
|
||||
|--------|------|-------------|---------------|
|
||||
| `0` | `DISPATCH` | Dispatches an event to the client | Receive |
|
||||
| `1` | `HEARTBEAT` | Fired periodically to keep the connection alive | Send/Receive |
|
||||
| `2` | `IDENTIFY` | Starts a new session during the initial handshake | Send |
|
||||
| `3` | `PRESENCE_UPDATE` | Updates the client presence | Send |
|
||||
| `4` | `VOICE_STATE_UPDATE` | Joins, moves, or disconnects from a voice channel | Send |
|
||||
| `5` | `VOICE_SERVER_PING` | Pings the voice server | Send |
|
||||
| `6` | `RESUME` | Resumes a previous session after a disconnect | Send |
|
||||
| `7` | `RECONNECT` | Indicates the client should reconnect to the gateway | Receive |
|
||||
| `8` | `REQUEST_GUILD_MEMBERS` | Requests members for a guild | Send |
|
||||
| `9` | `INVALID_SESSION` | Session has been invalidated; client should reconnect and identify | Receive |
|
||||
| `10` | `HELLO` | Sent immediately after connecting; contains heartbeat interval | Receive |
|
||||
| `11` | `HEARTBEAT_ACK` | Acknowledgement of a heartbeat | Receive |
|
||||
| `12` | `GATEWAY_ERROR` | Indicates an error occurred while processing a gateway message | Receive |
|
||||
| `14` | `LAZY_REQUEST` | Requests lazy-loaded guild data | Send |
|
||||
6
fluxer_docs/gateway/overview.mdx
Normal file
6
fluxer_docs/gateway/overview.mdx
Normal file
@@ -0,0 +1,6 @@
|
||||
---
|
||||
title: 'Gateway overview'
|
||||
description: 'How Fluxer gateway connections work at a high level.'
|
||||
---
|
||||
|
||||
TBD
|
||||
Reference in New Issue
Block a user