v1

latestOpenAPI 3.1.02026-07-2616459400.5 KB
WhatsApp Payments

Create Payment Configuration

Create a new payment gateway configuration for WhatsApp payments. This endpoint allows businesses to set up payment providers (such as PayU, RazorPay, etc.) with OAuth-based authentication and required merchant details for processing payments through WhatsApp.

post/v2/payments/configuration

Headers

Content-Type'application/json' required

Defines the content type of the request body. Must be application/json.

Request body

configuration_namestring required

Unique name for the payment configuration. This identifier will be used to reference the configuration in payment operations.

provider_namestring required

Name of the payment gateway provider (e.g., PayU, RazorPay, etc.)

redirect_urlstring uri

The callback URL where users will be redirected after completing OAuth authentication with the payment provider. Must be a valid HTTPS URL.

merchant_category_codestring required

Merchant Category Code (MCC) for the business. Used to classify the type of business and transactions.

purpose_codestring required

Purpose code indicating the nature of the payment transaction as per regulatory requirements.

merchant_vpastring

Merchant VPA for UPI payments.

Example request

{
  "configuration_name": "ravi_test2",
  "provider_name": "PayU",
  "redirect_url": "https://exampleravi.com/oauth",
  "merchant_category_code": "0000",
  "purpose_code": "00",
  "merchant_vpa": "rohanagarwalaxis@sksk"
}

Response

Payment configuration created successfully

statusstring required

Overall status of the API call

messagestring required

Human-readable message about the operation

Example response

{
  "status": "success",
  "message": "Payment configuration created successfully",
  "data": {
    "configuration_name": "ravi_test2",
    "provider_name": "PayU",
    "redirect_url": "https://exampleravi.com/oauth",
    "merchant_category_code": "0000",
    "purpose_code": "00",
    "status": "active"
  }
}