Skip to main content

Prerequisites

Integration Steps

To accept payments using Optimizer, follow the steps given below:

Step 1: Integrate With Razorpay Payment Gateway

You can start accepting payments by integrating your website, app, or ecommerce store with the Razorpay Payment Gateway through any of the integration methods available.

Payments API

Payments APIs are used to capture and fetch payments. The payment entity has one extra field with Optimizer to identify the payment provider through which the payment is processed. Given below is the additional response parameter apart from the Payment Entity: gateway_provider : string The payment provider used to process the payment. Possible values:
  • payu
  • cashfree
  • paytm
  • pinelabs
  • ccavenue
  • ingenico
  • billdesk_optimizer
Refer to Payments Entity for the rest of the parameters.
Payment Success

Webhooks

You can use Webhooks to configure and receive notifications when a specific event occurs. When an event is triggered, we send an HTTP POST payload in JSON to the webhook’s configured URL. You can set up Webhooks from the Dashboard. Given below is the sample payload for webhook events for Optimizer. All the parameters and events will remain the same as shown in the sample payloads for payment webhooks except for one additional parameter, gateway_provider.
Webhook Sample Payload

Step 2: Add Payment Providers

Watch this video to know how to add payment providers and configure rules using Optimizer. The Razorpay Dashboard offers a self-serve flow to add Payment Providers by submitting your details. This process is secure, and the details you add are fully encrypted which is only visible on your Dashboard. Know more about Razorpay Security.

Step 3: Configure Routing Rules

Create your rules on the Razorpay Dashboard to dynamically route transactions using different parameters like payment method, amount, issuer, and more. You can also add priorities in every rule to ensure transactions are routed to the best-performing gateway.