Toloka documentation

close_pool

toloka.client.TolokaClient.close_pool | Source code

close_pool(self, pool_id: str)

Stops distributing tasks from the pool

If all tasks done, the pool will be closed automatically.

Parameters Description

Parameters Type Description
pool_id str

ID of the pool that will be closed.

  • Returns:

    Pool object with new status.

  • Return type:

    Pool

Examples:

open_pool = next(toloka_client.get_pools(status='OPEN'))
toloka_client.close_pool(pool_id=open_pool.id)