Skip to content

@mega-yfue/eufy-sdk / prepareKeyExchange

Function: prepareKeyExchange() ​

ts
function prepareKeyExchange(localKeyHex?): KeyExchangePrep;

Build a key-exchange request: an ephemeral P-256 keypair whose public hex is AES-128-CBC(localKey)-encrypted, signed with the localKey-hex as UTF-8.

Parameters ​

localKeyHex? ​

string = EUFY_MEGA_LOCAL_KEY_HEX

Returns ​

KeyExchangePrep

Independent and unofficial. Not affiliated with, endorsed by, or sponsored by Anker Innovations, Anker eufy, or eufy. "Anker eufy", "eufy" and "Anker" are trademarks of their respective owners. Use responsibly — rapid or failed logins can trigger captcha or temporary cooldowns.