Layer 220
PaymentsConvertStarGift
Convert a received gift into Telegram Stars: this will permanently destroy the gift, converting it into star Gift. convert_stars Telegram Stars, added to the user's balance.
method
Users
Business
Parameters
| Name | Type | Description |
|---|---|---|
| Stargift | InputSavedStarGift | The gift to convert. |
Returns
BoolPossible Errors
| Code | Type | Description |
|---|---|---|
| 400 | BUSINESS_CONNECTION_INVALID | The connection_id passed to the wrapping invoke With Business Connection call is invalid. |
| 400 | MESSAGE_ID_INVALID | The provided message id is invalid. |
| 400 | SAVED_ID_EMPTY | The passed input Saved Star Gift Chat. saved_id is empty. |
| 400 | STARGIFT_PEER_INVALID | The specified input Saved Star Gift Chat. peer is invalid. |
| 400 | USER_ID_INVALID | The provided user ID is invalid. |
Gogram Example
// PaymentsConvertStarGift - positional arguments result, err := client.PaymentsConvertStarGift(&tg.InputSavedStarGift{}) if err != nil { // handle error } // result is *tg.Bool