> For the complete documentation index, see [llms.txt](https://docs.aethercube.fr/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.aethercube.fr/developers/protocol/packets.md). Agents can also search and read this documentation through its [MCP server](https://docs.aethercube.fr/~gitbook/mcp).

# Packet registry

Packet ids are allocated once and never reused. This page is a map: use it to find the packet you need, then read its message in `protocol/proto/`. The authoritative list is `protocol/packet_ids.md`. Direction is `C>S` (client to server) or `S>C` (server to client).

## Ranges

| Range                | Purpose                                                  | Schema file                                      |
| -------------------- | -------------------------------------------------------- | ------------------------------------------------ |
| `0x0001` to `0x00FF` | Connection, handshake, lifecycle, content packs          | `handshake.proto`, `content.proto`               |
| `0x0100` to `0x01FF` | World and chunk synchronisation                          | `world.proto`                                    |
| `0x0200` to `0x02FF` | Entities                                                 | `entity.proto`                                   |
| `0x0300` to `0x03FF` | Player input and corrections                             | `player.proto`                                   |
| `0x0400` to `0x04FF` | Combat and abilities                                     | `combat.proto`                                   |
| `0x0500` to `0x05FF` | Inventory and equipment                                  | `inventory.proto`                                |
| `0x0600` to `0x06FF` | Chat and messages                                        | `chat.proto`                                     |
| `0x0700` to `0x07FF` | Profile, stats, quests, notifications, screen effects    | `gameplay.proto`, `npc.proto`, `content.proto`   |
| `0x0800` to `0x08FF` | World interaction: containers, dialogue, shops, crafting | `inventory.proto`, `npc.proto`, `crafting.proto` |
| `0x0F00` to `0x0FFF` | Protocol errors                                          | `errors.proto`                                   |
| `0x1000` to `0xDFFF` | Reserved                                                 |                                                  |
| `0xE000` to `0xFFFE` | Experimental. Never in release builds.                   |                                                  |
| `0xFFFF`             | Invalid                                                  |                                                  |

## Connection

| Id       | Dir | Packet               |
| -------- | --- | -------------------- |
| `0x0001` | C>S | `ClientHello`        |
| `0x0002` | S>C | `ServerHello`        |
| `0x0003` | C>S | `ClientCapabilities` |
| `0x0004` | S>C | `ConnectionAccepted` |
| `0x0005` | S>C | `ConnectionRejected` |
| `0x0006` | C>S | `ClientKeepAlive`    |
| `0x0007` | S>C | `ServerKeepAlive`    |
| `0x0008` | C>S | `DisconnectRequest`  |
| `0x0009` | S>C | `DisconnectNotice`   |
| `0x000A` | S>C | `LoadingScreen`      |
| `0x000B` | S>C | `ContentPackList`    |
| `0x000C` | C>S | `ContentPackRequest` |
| `0x000D` | S>C | `ContentPackChunk`   |
| `0x000E` | C>S | `ContentPacksReady`  |
| `0x000F` | S>C | `ContentRegistry`    |

## World

| Id       | Dir | Packet                   |
| -------- | --- | ------------------------ |
| `0x0100` | S>C | `WorldInitialize`        |
| `0x0101` | S>C | `WorldTimeUpdate`        |
| `0x0102` | S>C | `WorldEnvironmentUpdate` |
| `0x0103` | S>C | `ChunkData`              |
| `0x0104` | S>C | `ChunkUnload`            |
| `0x0105` | S>C | `ChunkBatchBegin`        |
| `0x0106` | S>C | `ChunkBatchEnd`          |
| `0x0107` | S>C | `BlockChange`            |
| `0x0108` | S>C | `BlockChangeBatch`       |
| `0x0109` | S>C | `WorldBorderUpdate`      |
| `0x010A` | S>C | `BlockBreakProgress`     |

## Entities

| Id       | Dir | Packet                  |
| -------- | --- | ----------------------- |
| `0x0200` | S>C | `EntitySpawn`           |
| `0x0201` | S>C | `EntityDespawn`         |
| `0x0202` | S>C | `EntitySnapshot`        |
| `0x0203` | S>C | `EntitySnapshotBatch`   |
| `0x0204` | S>C | `EntityTeleport`        |
| `0x0205` | S>C | `EntityAnimation`       |
| `0x0206` | S>C | `EntityMetadataUpdate`  |
| `0x0207` | S>C | `EntityEquipmentUpdate` |
| `0x0208` | S>C | `EntityHealthUpdate`    |
| `0x0209` | S>C | `EntityEffectUpdate`    |
| `0x020A` | S>C | `BossBarUpdate`         |
| `0x020B` | S>C | `EntityRide`            |

## Player input

| Id       | Dir | Packet              |
| -------- | --- | ------------------- |
| `0x0300` | C>S | `PlayerInput`       |
| `0x0301` | C>S | `PlayerInputBatch`  |
| `0x0302` | S>C | `PlayerCorrection`  |
| `0x0303` | S>C | `PlayerMovementAck` |
| `0x0304` | C>S | `PlayerAction`      |
| `0x0305` | S>C | `PlayerStateUpdate` |
| `0x0306` | C>S | `PlayerInteraction` |

## Combat

| Id       | Dir | Packet               |
| -------- | --- | -------------------- |
| `0x0400` | C>S | `AttackRequest`      |
| `0x0401` | S>C | `AttackResult`       |
| `0x0402` | S>C | `DamageEvent`        |
| `0x0403` | C>S | `AbilityCastRequest` |
| `0x0404` | S>C | `AbilityCastResult`  |
| `0x0405` | S>C | `CooldownUpdate`     |
| `0x0406` | S>C | `EntityDeath`        |
| `0x0407` | S>C | `CombatEffect`       |
| `0x0408` | S>C | `AbilityLoadout`     |

## Inventory

| Id       | Dir | Packet                   |
| -------- | --- | ------------------------ |
| `0x0500` | S>C | `InventorySnapshot`      |
| `0x0501` | C>S | `InventoryAction`        |
| `0x0502` | S>C | `InventoryActionResult`  |
| `0x0503` | S>C | `InventorySlotUpdate`    |
| `0x0504` | C>S | `EquipmentChangeRequest` |
| `0x0505` | S>C | `EquipmentUpdate`        |
| `0x0506` | S>C | `ItemDropResult`         |
| `0x0507` | S>C | `ItemPickupResult`       |
| `0x0508` | S>C | `CreativeCatalog`        |
| `0x0509` | C>S | `CreativeSetSlot`        |
| `0x050A` | C>S | `PickBlock`              |
| `0x050B` | S>C | `PickBlockResult`        |

## Chat

| Id       | Dir | Packet               |
| -------- | --- | -------------------- |
| `0x0600` | C>S | `ChatMessageRequest` |
| `0x0601` | S>C | `ChatMessage`        |
| `0x0602` | S>C | `SystemMessage`      |
| `0x0603` | C>S | `ChatCommandRequest` |

## Profile and gameplay data

| Id       | Dir | Packet                   |
| -------- | --- | ------------------------ |
| `0x0700` | S>C | `PlayerProfileSnapshot`  |
| `0x0701` | S>C | `PlayerStatsUpdate`      |
| `0x0702` | S>C | `ExperienceUpdate`       |
| `0x0703` | S>C | `LevelUpdate`            |
| `0x0704` | S>C | `QuestUpdate`            |
| `0x0705` | S>C | `Notification`           |
| `0x0706` | S>C | `PlayerAppearanceUpdate` |
| `0x0707` | S>C | `PlayerResourcesUpdate`  |
| `0x0708` | S>C | `QuestLog`               |
| `0x0709` | C>S | `QuestAbandon`           |
| `0x070A` | S>C | `NpcQuestStatus`         |
| `0x070B` | S>C | `ScreenEffect`           |

## World interaction

| Id       | Dir  | Packet                  |
| -------- | ---- | ----------------------- |
| `0x0800` | S>C  | `ContainerOpen`         |
| `0x0801` | C>S  | `ContainerCloseRequest` |
| `0x0802` | S>C  | `ContainerClosed`       |
| `0x0803` | S>C  | `DialogueOpen`          |
| `0x0804` | C>S  | `DialogueChoice`        |
| `0x0805` | S>C  | `DialogueClose`         |
| `0x0806` | S>C  | `ShopOpen`              |
| `0x0807` | C>S  | `ShopTrade`             |
| `0x0808` | S>C  | `ShopTradeResult`       |
| `0x0809` | both | `ShopClose`             |
| `0x080A` | S>C  | `RecipeBook`            |
| `0x080B` | S>C  | `CraftingOpen`          |
| `0x080C` | C>S  | `CraftRequest`          |
| `0x080D` | S>C  | `CraftResult`           |
| `0x080E` | C>S  | `RepairRequest`         |
| `0x080F` | S>C  | `RepairResult`          |
| `0x0810` | S>C  | `ForgeProgress`         |

## Errors

| Id       | Dir | Packet               |
| -------- | --- | -------------------- |
| `0x0F00` | S>C | `ProtocolError`      |
| `0x0F01` | S>C | `RateLimitNotice`    |
| `0x0F02` | S>C | `FeatureUnavailable` |

## Compatibility rules

* The protocol version is checked at the handshake. It is bumped for a change that breaks existing clients.
* The `.proto` files are linted and checked for breaking changes with `buf`. See [Tests and checks](https://docs.aethercube.fr/developers/building-from-source/tests-and-checks.md).
* Test vectors written by the server and read by the client (frames, voxel encodings, a movement trace) are in `protocol/vectors/`. They keep the two implementations in agreement.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.aethercube.fr/developers/protocol/packets.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
