post https://api.juspay.in/customers//eligibility
Determines if a customer has a linked wallet with sufficient amount for the order.
Note:
- Either amount or the order_id should be present in the request so as to get the eligibility.
- gateway_data is gateway specific information, it can be mandatory for some
gatewaysFormat Supported:
- application/JSON
- application/x-www-form-urlencoded
Response Parameters for the Eligibility API: (click to view)
Parameter | Type | Description |
---|---|---|
payment_methods_eligibility: [{...},{...},..] | Array | An array of EligibilityData Objects. Lists all the payment methods which have eligibility criteria. (see table below) |
EligibilityData Object - provides details of each payment method of a customer.
Field | Type | Description |
---|---|---|
payment_method | String | Name of the Payment Method which has eligibility criteria |
payment_method_type | String | Type of the payment method, like WALLET |
description | String | Description about the payment method |
is_eligible | Boolean | Flag which specifies if the customer is eligible for the payment method |
eligibility_strategy | String | Different strategy of eligibility. like Transaction eligibility, User eligibility |
balance | Double | Balance given in the gateway eligibility response |
status | String | The Juspay mapped error status for the corresponding gateway error code (see Appendix below) |
due_date | String | Due date of the pay later option bill payment. |
gateway_error_code | String | Error code |
gateway_error_message | String | Error message given by gateway |
Gateway error codes and messages: (click to view)
Error Code | Error Message |
---|---|
OC_000 | Ola Postpaid available |
OC_011 | user not found |
Codes not listed in document, but found in actual response.
APPENDIX: Eligibility status codes and meaning (click to view)
Status code | Description |
---|---|
SUCCESS | Successful |
INSUFFICIENT_FUNDS | The wallet amount is less than the order amount |
USER_NOT_FOUND | User not found for that gateway |
BAD_REQUEST | Bad Request |
INVALID_DATA | Invalid header or input data or any of the values are expired |
NOT_ACCESSIBLE | When the user does not have access because of the insufficient credit limit or blocked to that wallet |
PENDING_DUES | Pending dues are present in the wallet which user needs to clear |
UNAUTHORIZED | Unauthorized |
ERROR | Any other error mapping |
Error Codes and Description: (click to view)
Error Code | Description |
---|---|
linking_required | Link the Simpl account |
pending_bill | Clear the previous dues to proceed |
insufficient_credit | Clear the previous dues to proceed |
unable_to_process | Transaction Amount exceeds spending limit |
user_unauthorized | User is not eligible to use Simpl |
⭣
The request consists of either amount and/or order_id, and other parameters, as listed below: