Autologin without user and password

exactly! I get the value of $value via API, but I don’t know what value to set for $key.
Any help please?