account.GetPaidMessagesRevenue

class pyrogram.raw.functions.account.GetPaidMessagesRevenue

Get the number of stars we have received from the specified user thanks to paid messages »; the received amount will be equal to the sent amount multiplied by stars_paid_message_commission_permille divided by 1000.

Details:
  • Layer: 227

  • ID: 19BA4A67

Parameters:
  • user_id (InputUser) – The user that paid to send us messages.

  • parent_peer (InputPeer, optional) – If set, can contain the ID of a monoforum (channel direct messages) to obtain the number of stars the user has spent to send us direct messages via the channel.

Returns:

account.PaidMessagesRevenue

TL Schema

account.getPaidMessagesRevenue#19ba4a67
flags:#
parent_peer:flags.0?InputPeer
user_id:InputUser

= account.PaidMessagesRevenue

Parameter Tree

GetPaidMessagesRevenue
├── parent_peer → InputPeer (optional)
│ ├── InputPeerEmpty
│ ├── InputPeerSelf
│ ├── InputPeerChat
│ │ └── chat_id → long
│ ├── InputPeerUser
│ │ ├── user_id → long
│ │ └── access_hash → long
│ ├── InputPeerChannel
│ │ ├── channel_id → long
│ │ └── access_hash → long
│ │ ├── peer → InputPeer
│ │ │ ├── InputPeerEmpty
│ │ │ ├── InputPeerSelf
│ │ │ ├── InputPeerChat
│ │ │ ├── InputPeerUser
│ │ │ ├── InputPeerChannel
│ │ │ ├── InputPeerUserFromMessage
│ │ │ └── InputPeerChannelFromMessage
│ │ ├── msg_id → int
│ │ └── user_id → long
│ ├── peer → InputPeer
│ │ ├── InputPeerEmpty
│ │ ├── InputPeerSelf
│ │ ├── InputPeerChat
│ │ ├── InputPeerUser
│ │ ├── InputPeerChannel
│ │ ├── InputPeerUserFromMessage
│ │ └── InputPeerChannelFromMessage
│ ├── msg_id → int
│ └── channel_id → long
└── user_id → InputUser
├── InputUserEmpty
├── InputUserSelf
├── InputUser
│ ├── user_id → long
│ └── access_hash → long
├── peer → InputPeer
│ ├── InputPeerEmpty
│ ├── InputPeerSelf
│ ├── InputPeerChat
│ ├── InputPeerUser
│ ├── InputPeerChannel
├── msg_id → int
└── user_id → long

Example

await app.invoke(
    GetPaidMessagesRevenue(
        parent_peer=await app.resolve_peer(chat_id),
        user_id=await app.resolve_user(chat_id),
    )
)