The toloka.yandex.com
domain will be disabled starting July 1, 2023. Please use the toloka.dev
domain for API requests.
Gets the list of Toloker bans.
Try our new API reference: more parameter details, request/response examples, and code samples in various programming languages, including the Toloka-Kit usage samples.
GET https://toloka.dev/api/v1/user-restrictionsAuthorization: OAuth <OAuth token>
Title | Overview |
---|---|
Authorization | A token for account authorization. Add OAuth as a prefix. |
Query parameters are specified in the link after the question mark and separated by &
.
Parameter | Overview |
---|---|
scope | string
|
user_id | string Toloker ID. |
project_id | string | required if Required if scope=PROJECT .The ID of the project that is blocked. |
pool_id | string | required if Required if scope=POOL .The ID of the pool that is blocked. |
sort | string
|
Standard query parameters | limit, id_gt, id_gte, id_lt, id_lte, created_gt, created_gte, created_lt, created_lte. |
To get the list of bans in parts (for example, 10 bans at a time), use a combination of parameters in requests:
GET https://toloka.dev/api/v1/user-restrictions?sort=id&limit=10Authorization: OAuth <OAuth token>
GET https://toloka.dev/api/v1/user-restrictions?sort=id&limit=10&id_gt=<id last ban from the answer to the previous query>Authorization: OAuth <OAuth token>
{"items" : [{ban parameters 1}, {ban parameters 2}, ... {ban parameters n}], "has_more": true}
Property | Description |
---|---|
items[] | array of objects Contains a list of bans. |
has_more | boolean Shows whether the list is complete. Acceptable values:
|