get_stars_transactions()

Client.get_stars_transactions()

Get Stars transaction history.

Usable by Users Bots
Parameters:
  • peer (int | str, optional) – Unique identifier (int) or username (str) of the peer. If not provided, gets your own transaction history.

  • inbound (bool, optional) – If True, only get incoming transactions.

  • outbound (bool, optional) – If True, only get outgoing transactions.

  • limit (int, optional) – Limits the number of transactions to be retrieved. By default, no limit is applied and all transactions are returned.

  • offset (str, optional) – Pagination offset.

Returns:

Generator – A generator yielding StarsTransaction objects.

Example

# Get all transactions
async for transaction in app.get_stars_transactions():
    print(transaction)

# Get only incoming transactions
async for transaction in app.get_stars_transactions(inbound=True):
    print(f"Received {transaction.amount}")