toloka.client.batch_create_results.WebhookSubscriptionBatchCreateResult
WebhookSubscriptionBatchCreateResult( self, *, items: Optional[Dict[str, WebhookSubscription]] = None, validation_errors: Optional[Dict[str, Dict[str, FieldValidationError]]] = None)
The result of creating webhook subscriptions.
WebhookSubscriptionBatchCreateResult
is returned by the upsert_webhook_subscriptions method.
Parameters | Type | Description |
---|---|---|
items | Optional[Dict[str, WebhookSubscription]] | A dictionary with created subscriptions. The indexes of a |
validation_errors | Optional[Dict[str, Dict[str, FieldValidationError]]] | A dictionary with validation errors. |
Examples:
result = toloka_client.upsert_webhook_subscriptions([ { 'webhook_url': 'https://awesome-requester.com/toloka-webhook', 'event_type': toloka.client.webhook_subscription.WebhookSubscription.EventType.ASSIGNMENT_CREATED, 'pool_id': '1240045' }])print(result.items['0'].created)
Last updated: August 28, 2023