telegram api method · layer 229 · #4ea9b3bf
payments.getStarsStatus
Get the current Telegram Stars balance of the current account (with peer=inputPeerSelf), or the stars balance of the bot specified in peer.
definition
payments.getStarsStatus#4ea9b3bf flags:# ton:flags.0?true peer:InputPeer = payments.StarsStatus;
parameters
| name | type | description |
|---|---|---|
flags | # | Flags, see TL conditional fields |
ton | true | If set, returns the channel/ad revenue balance in nanotons. |
peer | InputPeer | Peer of which to get the balance. |
returns
errors (5)
| code | error | description |
|---|---|---|
| 400 | BUSINESS_CONNECTION_INVALID | The connection_id passed to the wrapping invokeWithBusinessConnection call is invalid. |
| 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 | PEER_ID_INVALID | The provided peer id is invalid. |
| 401 | AUTH_KEY_UNREGISTERED | The specified authorization key is not registered in the system (for example, a PFS temporary key has expired). |
| 403 | BOT_ACCESS_FORBIDDEN | The specified method *can* be used over a business connection for some operations, but the specified query attempted an operation that is not allowed over a business connection. |
history
present in layers 181–229 · constructor id changed 1×
| id | layers |
|---|---|
| #104fcfa7 | 181–205 |
| #4ea9b3bf | 206–229 |