Open pool

Open a closed pool in Toloka.

Steps to follow

1. Import Toloka-Kit

Connect the Toloka-Kit library to your script.

import toloka.client as toloka

2. Instantiate TolokaClient

Replace the sample OAuth token with your own one.

toloka_client = toloka.

3. Open pool

Find out the ID of the pool you want to open. Then call the open_pool() method.

opened_pool = toloka_client.

4. Print pool ID and status

The open_pool() request will return the Pool class object. You can use its attributes to print the information you need.

print(, opened_pool.status)

You should get an output with the pool ID and the updated status which looks like this.

1442472 Status.OPEN

Complete code: Open pool

import toloka.client as toloka
toloka_client = toloka.TolokaClient('AQC2AGAJgyNSA8CtpdO9MWy_QEB6s6kDjHUoElE', 'PRODUCTION')
opened_pool = toloka_client.open_pool('1442472')
print(, opened_pool.status)
List of classes and methods used in this recipe

See also

OverviewGetting OAuth tokenQuick start
toloka.autoquality [autoquality]