---
page_title: Testing Methods 
product: Payment Gateway Integrations
page_source: https://juspay.io/in/docs/payment-gateway-integrations/docs/gateway-testing-guide/testing-methods
llms_txt: https://juspay.io/in/docs/llms.txt
product_llms_txt: https://juspay.io/in/docs/payment-gateway-integrations/llms.txt
---


# Testing Gateway Onboarding on Juspay 



This document explains the different ways to test a newly onboarded Payment Gateway (PG) on Juspay.The exact testing approach depends on:

* The setup available at your end
* What the Payment Gateway supports
* Your intended use case (UAT vs Production)

Based on these factors, multiple testing combinations are possible. Each combination and its recommended options are described below - 

1. Gateway UAT Testing on Juspay Sandbox
2. Gateway Production testing on Juspay Sandbox
3. Gateway Production testing on Juspay Production


## 1. Gateway UAT Testing on Juspay Sandbox 



This method is used when **Payment Gateway sandbox credentials**  are available.


### Important Notes



* Only **limited payment methods**  may be available.
* Transactions work only with **specific test cards, psp app**  provided by the PG.
* Ideal for early-stage validation of the gateway integration.


### Testing Options




#### Option 1: Disable All Other Gateways on Juspay Sandbox Dashboard



**Recommended when:** 

* You have very few active gateways on Juspay Sandbox, **or**
* You do not have the Juspay Sandbox APIs Postman collection set up.

**How it works:** 

* Deactivate all existing gateways on the Juspay Sandbox Dashboard.
* Keep only the newly configured gateway active.
* Since only one gateway is active, **all sandbox transactions will automatically route to it** .


---



#### Option 2: Use Gateway Reference ID



**Recommended when:** 

* You have the Juspay Sandbox APIs Postman collection ready.

**How it works:** 

1. While configuring the gateway on the Juspay Dashboard, assign a **unique Gateway Reference ID** .
2. In your Postman setup, pass this Gateway Reference ID in:
   
   * `Create Order API`, or
   * `Session API`
3. Juspay will route the transaction **only to the gateway matching that reference ID** .


## 2. Gateway Production Credentials Testing on Juspay Sandbox 



Some Payment Gateways allow Juspay’s **Sandbox environment to hit their Production systems** .


### When to use this



* The PG supports Juspay sandbox → PG production traffic.
* You want to **fully test real payment flows**  before going live.


### How it works



* Configure **Production credentials**  of the gateway on the Juspay **Sandbox Dashboard** .
* Set the gateway mode to **Production**  while configuration.
* You can now test **all payment methods using real money** , without impacting actual live traffic.


### Testing Method



* Follow **any of the testing options listed in Section 1**  (Disable other gateways or use Gateway Reference ID).

> **Warning**
> Before going live: Ensure the **Webhook URL**  is updated to the **Production webhook endpoint** .




## 3. Gateway Production Testing on Juspay Production 



This is used for final validation after sandbox testing. Production testing can be done in two controlled ways, depending on your setup.


### Option 1: Use Gateway Reference ID



**Recommended when:** 

* You have the Juspay **Production APIs Postman collection**  set up.

**How it works:** 

1. Assign a unique **Gateway Reference ID**  while configuring the gateway on the Juspay Production Dashboard.
2. Pass this reference ID in:
   
   * `Create Order API`, or
   * `Session API`
3. Only orders containing this reference ID will be routed to the gateway under test.


---



### Option 2: Use a Dedicated Priority Logic (PL)



**Recommended when:** 

* You have access to **internal test customer IDs**  that are sent to Juspay.

**How it works:** 

* Create an **enforced Priority Logic**  on the Juspay Production Dashboard.
* Add only your internal test customer IDs to this logic.
* Transactions from these customers will be routed **exclusively to the gateway being tested**  while none of your live traffic gets affected.

![Image](https://dth95m2xtyv8v.cloudfront.net/tesseract/assets/payment-gateway-integrations/image%20(6)-rDVco.png)
*Sample PL*



> **Warning**
> * If an existing Payment Gateway faces downtime, Juspay may reroute traffic to other active gateways—including the one under test.
> * To avoid unintended routing: **Disable or deactivate the gateway**  on the Juspay Dashboard when it is not actively being tested.




## FAQs & Troubleshooting



## FAQs:

### Error: "Payment Mode not active" 

This type of error occurs when a particular payment method is not activated for your account from the gateway end. You can get the exact error logs from the audit trail on the Juspay Dashboard and share it with the concerned PG to get it checked. 

### Error: "Can't find suitable gateway" 

This type of error occurs when gateway reference ID or gateway ID is missed in the request. In case gateway reference ID/gateway is passed correctly, the payment option being tested might not be enabled under the said gateway. 

### Error: "Unauthorized" or "Invalid API Key" 

This type of error usually occurs when the configured gateway credentials on the Juspay dashboard are configured incorrectly or there is a configuration miss at the Gateway end. This can be rectified by verifying the configuration or reaching out to the PG with the exact error message. 



---

## See Also

- [Get Started](https://juspay.io/in/docs/payment-gateway-integrations/docs/gateway-onboarding-guide/get-started)
- [Pine Labs](https://juspay.io/in/docs/payment-gateway-integrations/docs/payment-gateways/pine-labs)
