Class WebhookController

java.lang.Object
com.minicrm.mini_crm_api.controllers.WebhookController

@RestController @RequestMapping("/api/webhooks") public class WebhookController extends Object
Controller for handling incoming webhooks from external services.
  • Constructor Details

    • WebhookController

      public WebhookController()
  • Method Details

    • handleDeliveryReceipt

      @PostMapping("/delivery-receipt") public org.springframework.http.ResponseEntity<String> handleDeliveryReceipt(@RequestBody Map<String,String> payload)
      Accepts a delivery receipt and publishes it to a message queue for asynchronous batch processing. This endpoint returns immediately with a 202 Accepted status.
      Parameters:
      payload - A map containing the logId and the final delivery status.
      Returns:
      A ResponseEntity with HTTP status 202 Accepted.