feat: add paid webhook (#8721)

* feat: add BOOKING_PAID on enums

* feat: trigger the BOOKING_PAID webhook

* refactor: create payment variable

* feat: add REJECTED and REQUESTED on enums

* feat: create migration to booking werbhooks

* Update packages/features/webhooks/lib/constants.ts

Co-authored-by: Syed Ali Shahbaz <[email protected]>

* Update packages/prisma/schema.prisma

Co-authored-by: Syed Ali Shahbaz <[email protected]>

* Update packages/prisma/migrations/20230513235419_add_booking_webhooks/migration.sql

Co-authored-by: Syed Ali Shahbaz <[email protected]>

---------

Co-authored-by: Syed Ali Shahbaz <[email protected]>
Co-authored-by: alannnc <[email protected]>
Co-authored-by: Omar López <[email protected]>
This commit is contained in:
authored and GitHub committed 2023-06-13 14:57:59 +00:00
1 parent 4d30264950
commit 895b3ca7c9
4 files changed
+41 -6

No files matched your search

@@ -0,0 +1,9 @@
-- AlterEnum
-- This migration adds more than one value to an enum.
-- With PostgreSQL versions 11 and earlier, this is not possible
-- in a single migration. This can be worked around by creating
-- multiple migrations, each migration adding only one value to
-- the enum.
ALTER TYPE "WebhookTriggerEvents" ADD VALUE 'BOOKING_PAID';
+1
View File
@@ -498,6 +498,7 @@ enum PaymentOption {
enum WebhookTriggerEvents {
BOOKING_CREATED
BOOKING_PAID
BOOKING_RESCHEDULED
BOOKING_REQUESTED
BOOKING_CANCELLED