Toloka documentation


toloka.streaming.cursor.UserBonusCursor | Source code

    toloka_client: Union[TolokaClient, AsyncTolokaClient],
    user_id: Optional[str] = None,
    assignment_id: Optional[str] = None,
    private_comment: Optional[str] = None,
    id_lt: Optional[str] = None,
    id_lte: Optional[str] = None,
    id_gt: Optional[str] = None,
    id_gte: Optional[str] = None,
    created_lt: Optional[datetime] = None,
    created_lte: Optional[datetime] = None,
    created_gt: Optional[datetime] = None,
    created_gte: Optional[datetime] = None

Iterator over UserBonus instances by create time.

Parameters Description

Parameters Type Description
toloka_client Union[TolokaClient, AsyncTolokaClient]

TolokaClient object that is being used to search UserBonus instances.

request UserBonusSearchRequest

Base request to search UserBonus instances by.


Iterate over UserBonus instances.

it = UserBonusCursor(toloka_client=toloka_client)
current_bonuses = list(it)
# ... new `UserBonus` instances could appear ...
new_bonuses = list(it)  # Contains only new `UserBonus` instances, appeared since the previous call.