| 1 | import { HttpStatus } from '@nestjs/common'; |
| 2 | |
| 3 | import { DomainError } |
| 4 | |
| 5 | export class WebhookNotFoundError |
| 6 | status: number |
| 7 | |
| 8 | constructor() { |
| 9 | super('Webhook not found'); |
| 10 | } |
| 11 | } |
| 12 | |
| 13 | export class DeliveryNotFoundError |
| 14 | status: number |
| 15 | |
| 16 | constructor() { |
| 17 | super('Delivery not found'); |
| 18 | } |
| 19 | } |
| 20 | |
| 21 | export class InvalidWebhookUrlError |
| 22 | status: number |
| 23 | } |
| 24 | |
| 25 | export class WebhooksNotConfiguredError |
| 26 | status: number |
| 27 | |
| 28 | constructor() { |
| 29 | super( |
| 30 | 'Webhooks are not set up on this instance. An administrator needs to set WEBHOOK_SECRET_KEY.', |
| 31 | ); |
| 32 | } |
| 33 | } |