Skip to Content

WebhooksApi

All URIs are relative to https://business.apis.kesk.app/v1 

MethodHTTP requestDescription
handleRazorpaySubscriptionWebhookPOST /subscriptions/razorpayRazorpay subscription webhook endpoint using the generic service
handleRazorpayWebhookPOST /razorpay-webhook-listenerHandle Razorpay webhook events
handleRazorpayWebhookEnhancedPOST /razorpay-webhook-enhancedEnhanced Razorpay webhook endpoint with improved signature verification
handleStripeWebhookPOST /stripe-webhookHandle Stripe webhook events
whatsappWebhookNotificationPOST /whatsappWhatsApp POST endpoint for receiving notifications
whatsappWebhookVerificationGET /whatsappVerify WhatsApp webhook subscription

handleRazorpaySubscriptionWebhook

RazorpayWebhookAcknowledgeResponse handleRazorpaySubscriptionWebhook(x-razorpay-signature)

Razorpay subscription webhook endpoint using the generic service

Parameters

NameTypeDescriptionNotes
x-razorpay-signatureString[optional] [default to null]

Return type

RazorpayWebhookAcknowledgeResponse

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json; charset=utf-8

handleRazorpayWebhook

oas_any_type_not_mapped handleRazorpayWebhook(X-Razorpay-Signature)

Handle Razorpay webhook events

Receives and processes webhook notifications from Razorpay for payment and order events. # Security - Verifies webhook signature using X-Razorpay-Signature header - Prevents unauthorized webhook calls # Headers - `X-Razorpay-Signature`: Required. Webhook signature for verification

Parameters

NameTypeDescriptionNotes
X-Razorpay-SignatureStringRazorpay signature header for verification[default to null]

Return type

any

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json; charset=utf-8

handleRazorpayWebhookEnhanced

RazorpayWebhookAcknowledgeResponse handleRazorpayWebhookEnhanced(x-razorpay-signature)

Enhanced Razorpay webhook endpoint with improved signature verification

Parameters

NameTypeDescriptionNotes
x-razorpay-signatureString[optional] [default to null]

Return type

RazorpayWebhookAcknowledgeResponse

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json; charset=utf-8

handleStripeWebhook

StripeWebhookAcknowledgeResponse handleStripeWebhook(stripe-signature)

Handle Stripe webhook events

Unified webhook endpoint that receives and processes all Stripe events. Automatically routes subscription-related events (customer.subscription., invoice., checkout.session.completed) to the SubscriptionWebhookService, while other events are handled by the general WebhookService. # Security - Verifies webhook signature using Stripe-Signature header - Tracks webhook attempts for auditing - Prevents replay attacks through event deduplication # Headers - `Stripe-Signature`: Required. Webhook signature for verification

Parameters

NameTypeDescriptionNotes
stripe-signatureStringStripe signature header for verification[optional] [default to null]

Return type

StripeWebhookAcknowledgeResponse

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json; charset=utf-8

whatsappWebhookNotification

WhatsAppWebhookResponse whatsappWebhookNotification(signature_header)

WhatsApp POST endpoint for receiving notifications

Parameters

NameTypeDescriptionNotes
signature_headerString[optional] [default to null]

Return type

WhatsAppWebhookResponse

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json; charset=utf-8

whatsappWebhookVerification

MessageResponse whatsappWebhookVerification()

Verify WhatsApp webhook subscription

Called by WhatsApp to verify webhook endpoint during setup. Returns the challenge token if verification succeeds. # Query Parameters - `hub.mode`: Must be “subscribe” - `hub.verify_token`: Must match configured verification token - `hub.challenge`: Challenge string to echo back

Parameters

This endpoint does not need any parameter.

Return type

MessageResponse

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json; charset=utf-8