CentralPay

This app is the payment relay between your originating sites and Stripe.

Expected flow

Originating site CentralPay Stripe CentralPay originating site.

Key endpoints

  • POST /api/payments to create a payment request with X-CentralPay-Api-Key.
  • GET /pay/{paymentReference} to redirect a user to Stripe.
  • POST /api/webhooks/stripe/{siteId} for Stripe webhooks.
  • GET /api/payments/{paymentReference} for authoritative status.

Configuration model

For now, keep all development settings under the CentralPay configuration section, including site-level defaults such as ApiKey and optional top-level Products entries for product-specific gateway settings.

If productId is omitted, CentralPay keeps using the site-level configuration exactly as before. A sample product entry lives in appsettings.Development.json for local testing.