---
title: Hello (clientbound)
description: "Login 0x01, server → client."
---

`login` · `0x01` · **clientbound** (server → client)

Encryption request. Sent by the server after the serverbound `Hello` in online mode, carrying the `serverId`, its RSA `publicKey`, a random `verifyToken`, and `shouldAuthenticate`. The client generates a shared secret, contacts the session server if required, and replies with `Key`.

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

## Fields

| Field | Type | Notes |
|---|---|---|
| `serverId` | String |  |
| `publicKey` | Byte[] |  |
| `verifyToken` | Byte[] |  |
| `shouldAuthenticate` | Boolean |  |

## Send it

```ts
await client.sendPacket("Hello", {
  serverId: /* String */,
  publicKey: /* Byte[] */,
  verifyToken: /* Byte[] */,
  shouldAuthenticate: /* Boolean */,
});
```

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

Source: [`src/Core/Versions/776/Packets/login/clientbound/Hello.ts`](https://github.com/GDLev/mc-protocol/blob/master/src/Core/Versions/776/Packets/login/clientbound/Hello.ts)
