Docs
Account, keys and webhooks ›

List webhooks

GET/v1/webhooks

List your webhooks.

RequestTypeScript
  1. import { Agental } from "agental-sdk";
  2. const agental = new Agental();
  3. const webhooks = await agental.listWebhooks();
Answer200 OK
  1. {
  2. "webhooks": [{
  3. "id": string,
  4. "url": string,
  5. "events": string[],
  6. "description": string,
  7. "createdAt": string,
  8. "updatedAt": string,
  9. … 2 more
  10. }],
  11. }

Webhooks.

Headers

Authorizationrequired
Bearer key
An API key that may make this call.

Returns

200 Webhooks. Signing secrets are omitted.

JSON1 field
webhooks
object[]8 fields
id
string
url
string
events
string[]
description
string
createdAt
string
updatedAt
string
signingSecret
string
Returned only on create and rotate.
deliveries
object[]8 fields
id
string
event
string
status
string
httpStatus
integernull
error
stringnull
createdAt
string
eventId
stringnull
The id of the event this was a try of: the id in what was sent.
More An event that is not taken is tried again, eight times over about a day, under the same id.
attempt
integernull
Which try of that event this was, counted from 1.

Errors and other answers

404 Not found.

Every error answers { "error": { "code", "message" } }; a key without the action a call needs answers 403 key_action_forbidden, naming it.