WebhookClient
Hierarchy
- ResourceClient
- WebhookClient
Index
Methods
__init__
Initialize the WebhookClient.
Parameters
args: Any
kwargs: Any
Returns None
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 WebhookDispatchCollectionClient
WebhookDispatchCollectionClient: 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 Optional[Dict]
dict, optional: 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 Optional[Dict]
dict, optional: The webhook dispatch created by the test
update
Update the webhook.
https://docs.apify.com/api/v2#/reference/webhooks/webhook-object/update-webhook
Parameters
optionalkeyword-onlyevent_types: Optional[List[WebhookEventType]] = None
List of event types that should trigger the webhook. At least one is required.
optionalkeyword-onlyrequest_url: Optional[str] = None
URL that will be invoked once the webhook is triggered.
optionalkeyword-onlypayload_template: Optional[str] = None
Specification of the payload that will be sent to request_url
optionalkeyword-onlyactor_id: Optional[str] = None
Id of the actor whose runs should trigger the webhook.
optionalkeyword-onlyactor_task_id: Optional[str] = None
Id of the actor task whose runs should trigger the webhook.
optionalkeyword-onlyactor_run_id: Optional[str] = None
Id of the actor run which should trigger the webhook.
optionalkeyword-onlyignore_ssl_errors: Optional[bool] = None
Whether the webhook should ignore SSL errors returned by request_url
optionalkeyword-onlydo_not_retry: Optional[bool] = None
Whether the webhook should retry sending the payload to request_url upon failure.
optionalkeyword-onlyis_ad_hoc: Optional[bool] = None
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
dict: The updated webhook
Sub-client for manipulating a single webhook.