WebhookClientAsync
apify_client.clients.WebhookClientAsync
Index
Methods
delete
Delete the webhook.
https://docs.apify.com/api/v2#/reference/webhooks/webhook-object/delete-webhook
Returns None
dispatches
Get dispatches of the webhook.
https://docs.apify.com/api/v2#/reference/webhooks/dispatches-collection/get-collection
Returns WebhookDispatchCollectionClientAsync
A client allowing access to dispatches of this webhook using its list method
get
Retrieve the webhook.
https://docs.apify.com/api/v2#/reference/webhooks/webhook-object/get-webhook
Returns dict | None
The retrieved webhook, or None if it does not exist
test
Test a webhook.
Creates a webhook dispatch with a dummy payload.
https://docs.apify.com/api/v2#/reference/webhooks/webhook-test/test-webhook
Returns dict | None
The webhook dispatch created by the test
update
Update the webhook.
https://docs.apify.com/api/v2#/reference/webhooks/webhook-object/update-webhook
Parameters
event_types: list[WebhookEventType] | None = Nonekeyword-only
List of event types that should trigger the webhook. At least one is required.
request_url: str | None = Nonekeyword-only
URL that will be invoked once the webhook is triggered.
payload_template: str | None = Nonekeyword-only
Specification of the payload that will be sent to request_url
headers_template: str | None = Nonekeyword-only
Headers that will be sent to the request_url
actor_id: str | None = Nonekeyword-only
Id of the Actor whose runs should trigger the webhook.
actor_task_id: str | None = Nonekeyword-only
Id of the Actor task whose runs should trigger the webhook.
actor_run_id: str | None = Nonekeyword-only
Id of the Actor run which should trigger the webhook.
ignore_ssl_errors: bool | None = Nonekeyword-only
Whether the webhook should ignore SSL errors returned by request_url
do_not_retry: bool | None = Nonekeyword-only
Whether the webhook should retry sending the payload to request_url upon failure.
is_ad_hoc: bool | None = Nonekeyword-only
Set to True if you want the webhook to be triggered only the first time the condition is fulfilled. Only applicable when actor_run_id is filled.
Returns dict
The updated webhook
Async sub-client for manipulating a single webhook.