toloka.client.search_requests.UserBonusSortItems
UserBonusSortItems(self, items=None)
Keys for sorting rewards in search results.
Parameters | Type | Description |
---|---|---|
items | Optional[List[SortItem]] | A list of sorting keys. Supported values:
|
Examples:
The example shows how to find rewards sorted by granting date in descending order. Rewards with equal granting dates are sorted by IDs in ascending order.
sort = toloka.client.search_requests.UserBonusSortItems(['-created', 'id'])result = toloka_client.find_user_bonuses(user_id=best_toloker_id, sort=sort, limit=10)