telegram api method · layer 229 · #cdd42a05
auth.bindTempAuthKey
Binds a temporary authorization key temp_auth_key_id to the permanent authorization key perm_auth_key_id. Each permanent key may only be bound to one temporary key at a time, binding a new temporary key overwrites the previous one.
definition
auth.bindTempAuthKey#cdd42a05 perm_auth_key_id:long nonce:long expires_at:int encrypted_message:bytes = Bool;
parameters
| name | type | description |
|---|---|---|
perm_auth_key_id | long | Permanent auth_key_id to bind to |
nonce | long | Random long from Binding message contents |
expires_at | int | Unix timestamp to invalidate temporary key, see Binding message contents |
encrypted_message | bytes | See Generating encrypted_message |
returns
errors (5)
| code | error | description |
|---|---|---|
| 400 | BUSINESS_CONNECTION_NOT_ALLOWED | This method was invoked over a business connection using invokeWithBusinessConnection, but either (1) we're a user, and users cannot invoke methods over a business connection; (2) we're a bot, but business mode was disabled in @botfather or (3); we're a bot, but this method cannot be invoked over a business connection. |
| 400 | ENCRYPTED_MESSAGE_INVALID | Encrypted message invalid. |
| 400 | EXPIRES_AT_INVALID | The specified expires_at timestamp is invalid. |
| 400 | TEMP_AUTH_KEY_ALREADY_BOUND | The passed temporary key is already bound to another perm_auth_key_id. |
| 400 | TEMP_AUTH_KEY_EMPTY | No temporary auth key provided. |
history
present in layers 2–229
| id | layers |
|---|---|
| #cdd42a05 | 2–229 |