getPubKey (26)
The getPubKey message is used to request the public key of a specific user. It is primarily used by a client when adding a contact or when interacting with a bot to get the public key of another user within a group chat, which is necessary to verify their message signatures.
Core Data Types
IxiBytes: See IxiBytes Encoding.
Payload Structure
| Field | Data Type | Min | Max | Description |
|---|---|---|---|---|
targetAddress | IxiBytes | * | * | The address of the user whose public key is being requested. |
Behavioral Notes
- Standard Request: A user's client sends a
getPubKeymessage with an empty payload to a contact to ask for their public key. - Bot Request: A bot may receive a request from a user to identify another user in a chat. The bot would then send a
getPubKeymessage to the target user, including their address in thetargetAddressfield. - Response: Upon receiving a
getPubKeymessage, a node MUST respond with apubKeymessage containing the public key.