toloka.async_client.client.AsyncTolokaClient.compose_message_thread
| Source code
Sends a message to a Toloker.
The sent message is added to a new message thread.
Parameters | Type | Description |
---|---|---|
recipients_select_type | Union[RecipientsSelectType, str, None] | Method for specifying recipients |
topic | Optional[Dict[str, str]] | Post title. You can provide a title in several languages (the message will come in the Toloker's language). Format: "<language RU/EN/TR/ID/FR>": "<topic text>". |
text | Optional[Dict[str, str]] | Message text. You can provide text in several languages (the message will come in the Toloker's language). Format: "<language RU/EN/TR/ID/FR>": "<message text>". |
answerable | Optional[bool] | Ability to reply to a message:
|
recipients_ids | Optional[List[str]] | List of IDs of Tolokers to whom the message will be sent. |
recipients_filter | Optional[FilterCondition] | Filter to select recipients. |
Returns:
New created thread.
Return type:
Examples:
If you want to thank Tolokers who have tried to complete your tasks, send them a nice message.
message_text = "Amazing job! We've just trained our first model with the data YOU prepared for us. Thank you!"toloka_client.compose_message_thread( recipients_select_type='ALL', topic={'EN': 'Thank you!'}, text={'EN': message_text}, answerable=False)