Webhook
- class fabman.webhook.Webhook(requester: Requester, attributes: dict)
Class for interacting with the webhooks endpoint on the Fabman API
Initialize the Object. Stores the requester method to interact with the API for further calls
- Parameters:
requester (
Requester) – TheRequesterobject to make requests withattributes (dict) – The attributes to initialize this object with
- delete(**kwargs)
Deletes a webhook. WARNING: This is irreversible.
- Calls:
“DELETE /webhooks/{webhookId}” <https://fabman.io/api/v1/documentation#/webhooks/deleteWebhooksId>
- Returns:
response information of call
- Return type:
requests.Response
- get_events(**kwargs) Response
Returns the events for a webhook.
- Calls:
“GET /webhooks/{webhookId}/events” <https://fabman.io/api/v1/documentation#/webhooks/getWebhooksIdEvents>
- Returns:
response information of call
- Return type:
requests.Response
- send_test_event(**kwargs) Response
Sends a test event to the webhook.
- Calls:
“POST /webhooks/{webhookId}/events” <https://fabman.io/api/v1/documentation#/webhooks/postWebhooksIdTest>
- Returns:
response information of call
- Return type:
requests.Response
- update(**kwargs) None
Updates the webhook. Attributes are updated in place with new information
- Calls:
“PUT /webhooks/{webhookId}” <https://fabman.io/api/v1/documentation#/webhooks/putWebhooksId>
- Returns:
None – attributes are updated in place
- Return type:
None