Skip to content
mc-protocol
Esc
↑↓navigate↵open⌘Jpreview
On this page

Command Suggestion

Play 0x0F, client → server.

play · 0x0F · serverbound (client → server)

Asks the server for tab-completion suggestions. text is the current command line including the slash, transactionId identifies the request. The server replies with CommandSuggestions carrying the same id and the matching completions.

Sent by the client, read by the server. Listen for it with client.on("CommandSuggestion", (data) => …) on the receiving side.

Fields

Field Type Notes
transactionId VarInt
text String

Send it

await client.sendPacket("CommandSuggestion", {
  transactionId: /* VarInt */,
  text: /* String */,
});

Field aliases listed under Notes are accepted as alternative keys when writing.

Source: src/Core/Versions/776/Packets/play/serverbound/CommandSuggestion.ts

Was this page helpful?