### Eximbay Authorization Reversal API Response Source: https://context7.com/thanhnguyen162003/eximbay-docs/llms.txt Example response from the Eximbay Authorization Reversal API, confirming a successful reversal. It includes transaction details and a success message. ```http # Response: ver=230&mid=YOUR_MID&txntype=AUTH_REVERSAL&ref=ORD20221122003&cur=EUR&amt=75.50&transid=AUTH_123456789012345678&rescode=0000&resmsg=Reversal+successful&resdt=20221122180015&fgkey=RESPONSE_SHA256_HASH ``` -------------------------------- ### Transaction Query API Request Examples Source: https://context7.com/thanhnguyen162003/eximbay-docs/llms.txt Demonstrates how to query transaction details using either the transaction ID or the order reference number. Both methods require merchant ID and a security hash. ```http POST https://secureapi.eximbay.com/Gateway/DirectProcessor.krp Content-Type: application/x-www-form-urlencoded # Query by transaction ID: ver=230&mid=YOUR_MID&txntype=QUERY&keyfield=TRANSID&ref=ORD20221122001&cur=USD&amt=100.00&transid=TRANS123456789012345678&lang=EN&fgkey=GENERATED_SHA256_HASH # Query by reference: ver=230&mid=YOUR_MID&txntype=QUERY&keyfield=REF&ref=ORD20221122001&cur=USD&amt=100.00&lang=EN&fgkey=GENERATED_SHA256_HASH ``` -------------------------------- ### Eximbay Fraud Detection (DecisionManager) API Request Source: https://context7.com/thanhnguyen162003/eximbay-docs/llms.txt Example HTTP POST request to the Eximbay DecisionManager API for payment processing with fraud detection enabled. It includes all necessary parameters for a transaction. ```http POST https://secureapi.eximbay.com/Gateway/BasicProcessor.krp Content-Type: application/x-www-form-urlencoded # Payment with DM enabled (configured in merchant settings): ver=230&mid=YOUR_MID&txntype=PAYMENT&ref=ORD20221122006&cur=USD&amt=500.00&buyer=Test+Buyer&email=test@example.com&lang=EN&returnurl=https://yoursite.com/return&statusurl=https://yoursite.com/callback&item_1_productname=Electronics&item_1_quantity=1&item_1_unitprice=500.00&shipToFirstname=Test&shipToLastname=Buyer&shipToPhone=1234567890&shipToPostalcode=12345&shipToState=CA&shipToStreet=123+Test+St&shipToCity=Los+Angeles&shipToCountrycode=US&billToFirstname=Different&billToLastname=Person&billToPostalcode=54321&billToState=NY&billToStreet=789+Other+Ave&billToCity=New+York&billToCountrycode=US&displaytype=P&fgkey=GENERATED_SHA256_HASH ``` -------------------------------- ### Mobile Payment Integration API - Mobile Web Source: https://context7.com/thanhnguyen162003/eximbay-docs/llms.txt Optimizes payment processing for mobile devices by using the 'ostype=M' parameter for a mobile-optimized UI and 'displaytype=R' for a responsive page view. This example shows a mobile web payment request. ```http POST https://secureapi.eximbay.com/Gateway/BasicProcessor.krp Content-Type: application/x-www-form-urlencoded # Mobile web payment: ver=230&mid=YOUR_MID&txntype=PAYMENT&ref=MORD20221122001&cur=KRW&amt=50000&ostype=M&displaytype=R&buyer=김철수&email=kim@example.com&lang=KO&returnurl=https://m.yoursite.com/return&statusurl=https://yoursite.com/callback&item_1_productname=모바일+게임+아이템&item_1_quantity=10&item_1_unitprice=5000&shipToFirstname=철수&shipToLastname=김&shipToPhone=01012345678&shipToPostalcode=06234&shipToState=서울&shipToStreet=강남대로+123&shipToCity=강남구&shipToCountrycode=KR&fgkey=GENERATED_SHA256_HASH ``` -------------------------------- ### Capture Payment API Response and Error Handling Source: https://context7.com/thanhnguyen162003/eximbay-docs/llms.txt Details the expected response from the Capture API, including success and error codes. Provides a JavaScript example for handling different response codes and updating order statuses. ```http # Response: ver=230&mid=YOUR_MID&txntype=CAPTURE&ref=ORD20221122003&cur=EUR&amt=75.50&transid=AUTH_123456789012345678&rescode=0000&resmsg=Capture+successful&resdt=20221123091500&allowedpvoid=Y&fgkey=RESPONSE_SHA256_HASH ``` ```javascript # Error handling example: if (response.rescode === '0000') { // Success - update order status to 'captured' updateOrderStatus(ref, 'CAPTURED', response.transid); } else if (response.rescode === '1002') { // Original transaction not found logError('Capture failed: Transaction not found'); } else if (response.rescode === '2002') { // Already captured logError('Capture failed: Already captured'); } else { logError('Capture failed: ' + response.resmsg); } ``` -------------------------------- ### Eximbay Fraud Detection (DecisionManager) API Response Source: https://context7.com/thanhnguyen162003/eximbay-docs/llms.txt Example response from the Eximbay DecisionManager API, indicating the transaction details and the fraud decision (e.g., REVIEW). It includes fields like dm_decision and dm_review for further handling. ```http # Response with DM decision: ver=230&mid=YOUR_MID&txntype=PAYMENT&ref=ORD20221122006&cur=USD&amt=500.00&transid=TRANS_DM_123456789&rescode=0000&resmsg=Transaction+approved&dm_decision=REVIEW&dm_review=VC-ADDR-BM,VC-NEW-VEL&resdt=20221122171530&fgkey=RESPONSE_SHA256_HASH ``` -------------------------------- ### Eximbay Authorization Reversal API Request Source: https://context7.com/thanhnguyen162003/eximbay-docs/llms.txt Example HTTP POST request to the Eximbay Authorization Reversal API. This is used to cancel a previously authorized transaction before it's captured, releasing reserved funds. ```http POST https://secureapi.eximbay.com/Gateway/DirectProcessor.krp Content-Type: application/x-www-form-urlencoded ver=230&mid=YOUR_MID&txntype=AUTH_REVERSAL&ref=ORD20221122003&cur=EUR&amt=75.50&transid=AUTH_123456789012345678&lang=EN&fgkey=GENERATED_SHA256_HASH ``` -------------------------------- ### POST /Gateway/BasicProcessor.krp - 3D Secure Payer Authentication API Source: https://context7.com/thanhnguyen162003/eximbay-docs/llms.txt Initiates 3D Secure payer authentication for enhanced security verification before payment authorization or completion. Used with BasicProcessor for browser-based flows. ```APIDOC ## POST /Gateway/BasicProcessor.krp - 3D Secure Payer Authentication API ### Description Initiates the 3D Secure authentication process for cardholder verification. This step is crucial for enhanced security and fraud prevention before finalizing a payment or authorization. ### Method POST ### Endpoint https://secureapi.eximbay.com/Gateway/BasicProcessor.krp ### Parameters #### Query Parameters - **ver** (string) - Required - API version. Currently `230`. - **mid** (string) - Required - Merchant ID provided by Eximbay. - **txntype** (string) - Required - Transaction type. Set to `PAYER_AUTH` for this operation. - **ref** (string) - Required - Unique order reference number from the merchant. - **cur** (string) - Required - Transaction currency code (e.g., `USD`, `EUR`). - **amt** (decimal) - Required - Transaction amount. - **buyer** (string) - Optional - Buyer's name. - **email** (string) - Optional - Buyer's email address. - **lang** (string) - Optional - Language code for the payment page (e.g., `EN`). - **returnurl** (string) - Required - URL on the merchant's site where the user is redirected after authentication. - **statusurl** (string) - Required - URL on the merchant's site where Eximbay sends asynchronous authentication status updates. - **item_1_productname** (string) - Optional - Name of the first item in the order. - **item_1_quantity** (integer) - Optional - Quantity of the first item. - **item_1_unitprice** (decimal) - Optional - Unit price of the first item. - **shipToFirstname** (string) - Optional - First name of the shipping recipient. - **shipToLastname** (string) - Optional - Last name of the shipping recipient. - **shipToPhone** (string) - Optional - Phone number of the shipping recipient. - **shipToPostalcode** (string) - Optional - Postal code of the shipping address. - **shipToState** (string) - Optional - State or province of the shipping address. - **shipToStreet** (string) - Optional - Street address of the shipping recipient. - **shipToCity** (string) - Optional - City of the shipping address. - **shipToCountrycode** (string) - Optional - Two-letter country code of the shipping address. - **displaytype** (string) - Optional - Type of display for the payment page (e.g., `R` for redirect). - **fgkey** (string) - Required - SHA-256 hash of the request parameters for security. Calculated as SHA256(ver + mid + ref + cur + amt + returnurl + statusurl + SECRET_KEY). ### Request Example ``` POST https://secureapi.eximbay.com/Gateway/BasicProcessor.krp Content-Type: application/x-www-form-urlencoded ver=230&mid=YOUR_MID&txntype=PAYER_AUTH&ref=ORD20221122002&cur=USD&amt=250.00&buyer=Jane+Smith&email=jane@example.com&lang=EN&returnurl=https://yoursite.com/return&statusurl=https://yoursite.com/callback&item_1_productname=Tablet&item_1_quantity=1&item_1_unitprice=250.00&shipToFirstname=Jane&shipToLastname=Smith&shipToPhone=9876543210&shipToPostalcode=67890&shipToState=NY&shipToStreet=456+Oak+Ave&shipToCity=New+York&shipToCountrycode=US&displaytype=R&fgkey=GENERATED_SHA256_HASH ``` ### Response #### Success Response (200 - to statusurl) - **ver** (string) - API version. - **mid** (string) - Merchant ID. - **txntype** (string) - Transaction type (`PAYER_AUTH`). - **ref** (string) - Order reference number. - **cur** (string) - Transaction currency. - **amt** (decimal) - Transaction amount. - **transid** (string) - Eximbay's unique transaction ID for the authentication. - **payerauthid** (string) - Unique ID for the payer authentication transaction, used for subsequent payment. - **rescode** (string) - Response code (e.g., `0000` for success). - **resmsg** (string) - Response message. - **resdt** (string) - Date and time of the response (format: YYYYMMDDHHMMSS). - **cavv** (string) - Cardholder Authentication Verification Value (from 3D Secure). - **xid** (string) - Transaction identifier from the Directory Server. - **eci** (string) - Electronic Commerce Indicator. - **cardno1** (string) - First four digits of the card number. - **cardno4** (string) - Last four digits of the card number. - **fgkey** (string) - SHA-256 hash of the response parameters for security. #### Response Example ``` ver=230&mid=YOUR_MID&txntype=PAYER_AUTH&ref=ORD20221122002&cur=USD&amt=250.00&transid=PA_123456789012345678&payerauthid=PAUTH_1234567890123456&rescode=0000&resmsg=Authentication+successful&resdt=20221122154530&cavv=AAABBZIHCQAAAAATaKmwEwAAAAA=&xid=MDAwMDAwMDAwMDAwMDAwMzIyNzY=&eci=05&cardno1=5555&cardno4=4444&fgkey=RESPONSE_SHA256_HASH ``` ### Follow-up Transaction After successful payer authentication, use the `payerauthid` to complete the payment using the `PAYMENT_PA` transaction type with the DirectProcessor. ```http POST https://secureapi.eximbay.com/Gateway/DirectProcessor.krp ver=230&mid=YOUR_MID&txntype=PAYMENT_PA&ref=ORD20221122002&cur=USD&amt=250.00&payerauthid=PAUTH_1234567890123456&lang=EN&fgkey=GENERATED_SHA256_HASH ``` ``` -------------------------------- ### Recurring Payment Initial Payment (Token Creation) Source: https://context7.com/thanhnguyen162003/eximbay-docs/llms.txt Initiates the first payment for a recurring subscription, which also creates a payment token for future rebills. Requires customer details, payment amount, return URLs, and a security hash. ```http # Initial payment to create token (requires pre-approval from Eximbay): POST https://secureapi.eximbay.com/Gateway/BasicProcessor.krp ver=230&mid=YOUR_MID&txntype=PAYMENT&ref=SUB20221122001&cur=USD&amt=29.99&buyer=Sarah+Wilson&email=sarah@example.com&lang=EN&returnurl=https://yoursite.com/return&statusurl=https://yoursite.com/callback&item_1_productname=Monthly+Subscription&item_1_quantity=1&item_1_unitprice=29.99&shipToFirstname=Sarah&shipToLastname=Wilson&shipToPhone=3335557777&shipToPostalcode=98101&shipToState=WA&shipToStreet=789+Pine+St&shipToCity=Seattle&shipToCountrycode=US&displaytype=P&fgkey=GENERATED_SHA256_HASH ``` -------------------------------- ### Automated Subscription Billing Logic Source: https://context7.com/thanhnguyen162003/eximbay-docs/llms.txt Processes monthly subscription rebills using the Eximbay rebill API. ```APIDOC ## Automated Subscription Billing Logic ### Description Processes monthly subscription rebills using the Eximbay rebill API. This function generates a rebill request object and calls the Eximbay rebill service. ### Method POST (Implicit, as `callEximbayRebill` is assumed to be a POST request) ### Endpoint Assumed to be Eximbay's rebill endpoint. ### Parameters #### Request Body (Implicitly generated within `processMonthlySubscription`) - **subscription** (object) - Contains subscription details: - **id** (string) - Unique identifier for the subscription. - **currency** (string) - Currency code for the transaction (e.g., 'USD'). - **amount** (string) - The amount to be rebilled. - **tokenID** (string) - Token ID for recurring payment. - **customerName** (string) - Name of the customer. - **customerEmail** (string) - Email address of the customer. ### Request Example (Internal logic) ```javascript { "ver": "230", "mid": "YOUR_MID", "txntype": "REBILL", "ref": "SUB20231027", // Example ref format "cur": "USD", "amt": "50.00", "tokenID": "TOKEN12345", "buyer": "John Doe", "email": "john.doe@example.com", "lang": "EN", "fgkey": "GENERATED_FGKEY" } ``` ### Response #### Success Response Details of the rebill transaction as returned by `callEximbayRebill`. #### Response Example (Conceptual) ```json { "status": "success", "transactionId": "REBILL123456", "message": "Rebill successful" } ``` ``` -------------------------------- ### Mobile Payment Integration API Source: https://context7.com/thanhnguyen162003/eximbay-docs/llms.txt Provides optimized payment processing for mobile devices and in-app purchases. ```APIDOC ## Mobile Payment Integration API ### Description Optimized payment processing for mobile devices and in-app purchases. Supports responsive UI for mobile web and app callback functionality for seamless integration with mobile applications. ### Method POST ### Endpoint `https://secureapi.eximbay.com/Gateway/BasicProcessor.krp` ### Parameters #### Query Parameters - **ostype** (string) - Optional - Set to 'M' to enable a mobile-optimized UI. - **displaytype** (string) - Optional - Set to 'R' for a responsive page view. 'P' is for popup. - **callfromapp** (string) - Optional - Set to 'Y' to indicate an in-app purchase. - **callfromscheme** (string) - Optional - A custom URL scheme (e.g., `yourapp://payment`) for returning to the app after payment. - **ver** (string) - Required - API version, typically '230'. - **mid** (string) - Required - Merchant ID. - **txntype** (string) - Required - Transaction type, should be 'PAYMENT'. - **ref** (string) - Required - Unique reference number for the transaction. - **cur** (string) - Required - Currency code (e.g., 'KRW', 'JPY'). - **amt** (string) - Required - Transaction amount. - **buyer** (string) - Required - Buyer's name. - **email** (string) - Required - Buyer's email address. - **lang** (string) - Required - Language code (e.g., 'KO', 'JP'). - **returnurl** (string) - Required - URL to redirect the user after payment. - **statusurl** (string) - Required - URL for receiving transaction status notifications. - **item_1_productname** (string) - Required - Name of the first item. - **item_1_quantity** (string) - Required - Quantity of the first item. - **item_1_unitprice** (string) - Required - Unit price of the first item. - **shipToFirstname** (string) - Optional - Shipping first name. - **shipToLastname** (string) - Optional - Shipping last name. - **shipToPhone** (string) - Optional - Shipping phone number. - **shipToPostalcode** (string) - Optional - Shipping postal code. - **shipToState** (string) - Optional - Shipping state/province. - **shipToStreet** (string) - Optional - Shipping street address. - **shipToCity** (string) - Optional - Shipping city. - **shipToCountrycode** (string) - Optional - Shipping country code. - **fgkey** (string) - Required - Security hash key. ### Request Example (Mobile Web Payment) ```http POST https://secureapi.eximbay.com/Gateway/BasicProcessor.krp Content-Type: application/x-www-form-urlencoded ver=230&mid=YOUR_MID&txntype=PAYMENT&ref=MORD20221122001&cur=KRW&amt=50000&ostype=M&displaytype=R&buyer=김철수&email=kim@example.com&lang=KO&returnurl=https://m.yoursite.com/return&statusurl=https://yoursite.com/callback&item_1_productname=모바일+게임+아이템&item_1_quantity=10&item_1_unitprice=5000&shipToFirstname=철수&shipToLastname=김&shipToPhone=01012345678&shipToPostalcode=06234&shipToState=서울&shipToStreet=강남대로+123&shipToCity=강남구&shipToCountrycode=KR&fgkey=GENERATED_SHA256_HASH ``` ### Request Example (In-App Payment) ```http POST https://secureapi.eximbay.com/Gateway/BasicProcessor.krp Content-Type: application/x-www-form-urlencoded ver=230&mid=YOUR_MID&txntype=PAYMENT&ref=APPORD20221122001&cur=JPY&amt=1200&ostype=M&displaytype=R&callfromapp=Y&callfromscheme=yourapp://payment&buyer=田中太郎&email=tanaka@example.jp&lang=JP&returnurl=https://yoursite.com/return&statusurl=https://yoursite.com/callback&item_1_productname=アプリ内購入&item_1_quantity=1&item_1_unitprice=1200&shipToFirstname=太郎&shipToLastname=田中&shipToPhone=09012345678&shipToPostalcode=100-0001&shipToState=東京都&shipToStreet=千代田区+1-1&shipToCity=千代田区&shipToCountrycode=JP&fgkey=GENERATED_SHA256_HASH ``` ### Response #### Success Response (200) Standard payment gateway response, potentially including fields relevant to mobile or in-app transactions. #### Response Example ```json { "status": "pending_app_confirmation", "transactionId": "APPTRANS987654", "message": "Awaiting confirmation from the app." } ``` ``` -------------------------------- ### Dynamic Currency Conversion (DCC) API Source: https://context7.com/thanhnguyen162003/eximbay-docs/llms.txt Allows international customers to pay in their local currency with real-time exchange rates. ```APIDOC ## Dynamic Currency Conversion (DCC) API ### Description Enables international customers to complete transactions in their preferred local currency. The API provides real-time exchange rates, displaying the converted amount to the customer during checkout. This feature must be enabled in the merchant's Eximbay settings. ### Method POST ### Endpoint `https://secureapi.eximbay.com/Gateway/BasicProcessor.krp` ### Parameters #### Query Parameters - **cur** (string) - Required - The merchant's settlement currency (e.g., 'USD'). - **amt** (string) - Required - The amount in the merchant's settlement currency. - **basecur** (string) - Optional - If DCC is enabled and customer selects a different currency, this will be the customer's chosen currency (e.g., 'EUR'). - **baseamt** (string) - Optional - The converted amount in the customer's chosen currency. - **baserate** (string) - Optional - The exchange rate applied (calculated as `baseamt = amt * baserate`). - **ver** (string) - Required - API version, typically '230'. - **mid** (string) - Required - Merchant ID. - **txntype** (string) - Required - Transaction type, should be 'PAYMENT'. - **ref** (string) - Required - Unique reference number for the transaction. - **buyer** (string) - Required - Buyer's name. - **email** (string) - Required - Buyer's email address. - **lang** (string) - Required - Language code (e.g., 'EN'). - **returnurl** (string) - Required - URL to redirect the user after payment. - **statusurl** (string) - Required - URL for receiving transaction status notifications. - **item_1_productname** (string) - Required - Name of the first item. - **item_1_quantity** (string) - Required - Quantity of the first item. - **item_1_unitprice** (string) - Required - Unit price of the first item. - **shipToFirstname** (string) - Optional - Shipping first name. - **shipToLastname** (string) - Optional - Shipping last name. - **shipToPhone** (string) - Optional - Shipping phone number. - **shipToPostalcode** (string) - Optional - Shipping postal code. - **shipToState** (string) - Optional - Shipping state/province. - **shipToStreet** (string) - Optional - Shipping street address. - **shipToCity** (string) - Optional - Shipping city. - **shipToCountrycode** (string) - Optional - Shipping country code. - **displaytype** (string) - Optional - Display type ('P' for popup, 'R' for responsive). - **fgkey** (string) - Required - Security hash key. ### Request Example ```http POST https://secureapi.eximbay.com/Gateway/BasicProcessor.krp Content-Type: application/x-www-form-urlencoded ver=230&mid=YOUR_MID&txntype=PAYMENT&ref=ORD20221122005&cur=USD&amt=199.99&buyer=Hans+Mueller&email=hans@example.de&lang=EN&returnurl=https://yoursite.com/return&statusurl=https://yoursite.com/callback&item_1_productname=Software+License&item_1_quantity=1&item_1_unitprice=199.99&shipToFirstname=Hans&shipToLastname=Mueller&shipToPhone=+4912345678&shipToPostalcode=10115&shipToState=Berlin&shipToStreet=Unter+den+Linden+1&shipToCity=Berlin&shipToCountrycode=DE&displaytype=P&fgkey=GENERATED_SHA256_HASH ``` ### Response #### Success Response (200) - **cur** (string) - Original merchant currency. - **amt** (string) - Original merchant amount. - **basecur** (string) - Customer's chosen local currency. - **baseamt** (string) - Converted amount in the customer's local currency. - **baserate** (string) - Exchange rate applied. - **transid** (string) - Transaction ID. - **rescode** (string) - Response code, '0000' indicates success. - **resmsg** (string) - Response message. - **resdt** (string) - Response date and time. - **cardholder** (string) - Cardholder's name. - **accesscountry** (string) - Country code of the transaction origin. #### Response Example ``` ver=230&mid=YOUR_MID&txntype=PAYMENT&ref=ORD20221122005&cur=USD&amt=199.99&basecur=EUR&baseamt=186.45&baserate=0.9323&transid=TRANS_DCC_123456789&rescode=0000&resmsg=Transaction+approved&resdt=20221122170045&cardholder=HANS+MUELLER&accesscountry=DE&fgkey=RESPONSE_SHA256_HASH ``` ``` -------------------------------- ### Transaction Query API Response and Use Case Source: https://context7.com/thanhnguyen162003/eximbay-docs/llms.txt Details the response structure for transaction queries, including comprehensive transaction data and status. Includes a JavaScript function to verify payment status before shipping. ```http # Response includes all original transaction data: ver=230&mid=YOUR_MID&txntype=QUERY&ref=ORD20221122001&cur=USD&amt=100.00&transid=TRANS123456789012345678&rescode=0000&resmsg=Query+successful&authcode=12345678&resdt=20221122153045&status=Success&paymethod=P101&paytype=VISA&buyer=John+Doe&email=john@example.com&cardholder=JOHN+DOE&cardno1=4111&cardno4=1111&accesscountry=US&dm_decision=ACCEPT&fgkey=RESPONSE_SHA256_HASH ``` ```javascript # Use case - verify payment before shipping: function verifyPaymentBeforeShipping(orderRef) { const queryResponse = callEximbayQuery(orderRef); if (queryResponse.rescode === '0000' && queryResponse.status === 'Success' && queryResponse.dm_decision === 'ACCEPT') { return true; // Safe to ship } return false; // Hold shipment } ``` -------------------------------- ### POST /Gateway/BasicProcessor.krp - Authorization API Source: https://context7.com/thanhnguyen162003/eximbay-docs/llms.txt Reserves funds on a customer's payment method without immediate capture. Useful for verifying funds or processing orders before final billing. Uses BasicProcessor for browser-based flows. ```APIDOC ## POST /Gateway/BasicProcessor.krp - Authorization API ### Description Reserves funds on the customer's payment method for a specified amount without capturing the payment immediately. This is useful for verifying card validity and funds availability before shipment or final order confirmation. ### Method POST ### Endpoint https://secureapi.eximbay.com/Gateway/BasicProcessor.krp ### Parameters #### Query Parameters - **ver** (string) - Required - API version. Currently `230`. - **mid** (string) - Required - Merchant ID provided by Eximbay. - **txntype** (string) - Required - Transaction type. Set to `AUTHORIZE` for this operation. - **ref** (string) - Required - Unique order reference number from the merchant. - **cur** (string) - Required - Transaction currency code (e.g., `USD`, `EUR`). - **amt** (decimal) - Required - Transaction amount to authorize. - **buyer** (string) - Optional - Buyer's name. - **email** (string) - Optional - Buyer's email address. - **lang** (string) - Optional - Language code for the payment page (e.g., `EN`). - **returnurl** (string) - Required - URL on the merchant's site where the user is redirected after authorization. - **statusurl** (string) - Required - URL on the merchant's site where Eximbay sends asynchronous authorization status updates. - **item_1_productname** (string) - Optional - Name of the first item in the order. - **item_1_quantity** (integer) - Optional - Quantity of the first item. - **item_1_unitprice** (decimal) - Optional - Unit price of the first item. - **shipToFirstname** (string) - Optional - First name of the shipping recipient. - **shipToLastname** (string) - Optional - Last name of the shipping recipient. - **shipToPhone** (string) - Optional - Phone number of the shipping recipient. - **shipToPostalcode** (string) - Optional - Postal code of the shipping address. - **shipToState** (string) - Optional - State or province of the shipping address. - **shipToStreet** (string) - Optional - Street address of the shipping recipient. - **shipToCity** (string) - Optional - City of the shipping address. - **shipToCountrycode** (string) - Optional - Two-letter country code of the shipping address. - **displaytype** (string) - Optional - Type of display for the payment page (e.g., `P` for popup). - **fgkey** (string) - Required - SHA-256 hash of the request parameters for security. Calculated as SHA256(ver + mid + ref + cur + amt + returnurl + statusurl + SECRET_KEY). ### Request Example ``` POST https://secureapi.eximbay.com/Gateway/BasicProcessor.krp Content-Type: application/x-www-form-urlencoded ver=230&mid=YOUR_MID&txntype=AUTHORIZE&ref=ORD20221122003&cur=EUR&amt=75.50&buyer=Michael+Brown&email=michael@example.com&lang=EN&returnurl=https://yoursite.com/return&statusurl=https://yoursite.com/callback&item_1_productname=Book+Set&item_1_quantity=3&item_1_unitprice=25.17&shipToFirstname=Michael&shipToLastname=Brown&shipToPhone=5551234567&shipToPostalcode=SW1A+1AA&shipToState=London&shipToStreet=10+Downing+St&shipToCity=Westminster&shipToCountrycode=GB&displaytype=P&fgkey=GENERATED_SHA256_HASH ``` ### Response #### Success Response (200 - to statusurl) - **ver** (string) - API version. - **mid** (string) - Merchant ID. - **txntype** (string) - Transaction type (`AUTHORIZE`). - **ref** (string) - Order reference number. - **cur** (string) - Transaction currency. - **amt** (decimal) - Authorized amount. - **transid** (string) - Eximbay's unique transaction ID for the authorization. - **rescode** (string) - Response code (e.g., `0000` for success). - **resmsg** (string) - Response message. - **authcode** (string) - Authorization code from the bank. - **resdt** (string) - Date and time of the response (format: YYYYMMDDHHMMSS). - **status** (string) - Transaction status (e.g., `Authorized`). - **fgkey** (string) - SHA-256 hash of the response parameters for security. #### Response Example ``` ver=230&mid=YOUR_MID&txntype=AUTHORIZE&ref=ORD20221122003&cur=EUR&amt=75.50&transid=AUTH_123456789012345678&rescode=0000&resmsg=Authorization+approved&authcode=87654321&resdt=20221122160015&status=Authorized&fgkey=RESPONSE_SHA256_HASH ``` ``` -------------------------------- ### Eximbay Authorization API (HTTP POST) Source: https://context7.com/thanhnguyen162003/eximbay-docs/llms.txt Reserves funds on a customer's payment method without immediate capture. This is useful for verifying funds before confirming an order. It uses the BasicProcessor endpoint, and the response indicates whether the authorization was successful. ```http POST https://secureapi.eximbay.com/Gateway/BasicProcessor.krp Content-Type: application/x-www-form-urlencoded ver=230&mid=YOUR_MID&txntype=AUTHORIZE&ref=ORD20221122003&cur=EUR&amt=75.50&buyer=Michael+Brown&email=michael@example.com&lang=EN&returnurl=https://yoursite.com/return&statusurl=https://yoursite.com/callback&item_1_productname=Book+Set&item_1_quantity=3&item_1_unitprice=25.17&shipToFirstname=Michael&shipToLastname=Brown&shipToPhone=5551234567&shipToPostalcode=SW1A+1AA&shipToState=London&shipToStreet=10+Downing+St&shipToCity=Westminster&shipToCountrycode=GB&displaytype=P&fgkey=GENERATED_SHA256_HASH # Response: ver=230&mid=YOUR_MID&txntype=AUTHORIZE&ref=ORD20221122003&cur=EUR&amt=75.50&transid=AUTH_123456789012345678&rescode=0000&resmsg=Authorization+approved&authcode=87654321&resdt=20221122160015&status=Authorized&fgkey=RESPONSE_SHA256_HASH ``` -------------------------------- ### Multiple Payment Methods API Source: https://context7.com/thanhnguyen162003/eximbay-docs/llms.txt Enables customers to choose from multiple payment options on the payment page. ```APIDOC ## Multiple Payment Methods API ### Description Allows customers to select from a variety of payment methods on the checkout page. This is achieved by specifying a comma-separated list of payment method codes in the `multi_paymethod` parameter. ### Method POST ### Endpoint `https://secureapi.eximbay.com/Gateway/BasicProcessor.krp` ### Parameters #### Query Parameters - **multi_paymethod** (string) - Required - A hyphen-separated string of payment method codes (e.g., `P101-P102-P001-P174`). - **ver** (string) - Required - API version, typically '230'. - **mid** (string) - Required - Merchant ID. - **txntype** (string) - Required - Transaction type, should be 'PAYMENT'. - **ref** (string) - Required - Unique reference number for the transaction. - **cur** (string) - Required - Currency code (e.g., 'USD'). - **amt** (string) - Required - Transaction amount. - **buyer** (string) - Required - Buyer's name. - **email** (string) - Required - Buyer's email address. - **lang** (string) - Required - Language code (e.g., 'EN'). - **returnurl** (string) - Required - URL to redirect the user after payment. - **statusurl** (string) - Required - URL for receiving transaction status notifications. - **item_1_productname** (string) - Required - Name of the first item. - **item_1_quantity** (string) - Required - Quantity of the first item. - **item_1_unitprice** (string) - Required - Unit price of the first item. - **shipToFirstname** (string) - Optional - Shipping first name. - **shipToLastname** (string) - Optional - Shipping last name. - **shipToPhone** (string) - Optional - Shipping phone number. - **shipToPostalcode** (string) - Optional - Shipping postal code. - **shipToState** (string) - Optional - Shipping state/province. - **shipToStreet** (string) - Optional - Shipping street address. - **shipToCity** (string) - Optional - Shipping city. - **shipToCountrycode** (string) - Optional - Shipping country code. - **displaytype** (string) - Optional - Display type ('P' for popup, 'R' for responsive). - **fgkey** (string) - Required - Security hash key. #### Payment Method Codes - **P000** - All credit cards - **P101** - VISA - **P102** - MasterCard - **P103** - AMEX - **P104** - JCB - **P105** - UnionPay 2D - **P001** - PayPal - **P002** - UnionPay - **P003** - Alipay Plus - **P174** - Alipay CN - **P141** - WeChat PC - **P142** - WeChat Mobile - **P185** - GrabPay SGD - **P186** - LINE Pay - **P011** - Yandex ### Request Example ```http POST https://secureapi.eximbay.com/Gateway/BasicProcessor.krp Content-Type: application/x-www-form-urlencoded ver=230&mid=YOUR_MID&txntype=PAYMENT&ref=ORD20221122004&cur=USD&amt=150.00&multi_paymethod=P101-P102-P001-P174&buyer=David+Lee&email=david@example.com&lang=EN&returnurl=https://yoursite.com/return&statusurl=https://yoursite.com/callback&item_1_productname=Electronics&item_1_quantity=1&item_1_unitprice=150.00&shipToFirstname=David&shipToLastname=Lee&shipToPhone=4445556666&shipToPostalcode=10001&shipToState=NY&shipToStreet=321+Broadway&shipToCity=New+York&shipToCountrycode=US&displaytype=P&fgkey=GENERATED_SHA256_HASH ``` ### Response #### Success Response (200) - **paymethod** (string) - The payment method code that was used for the transaction (e.g., 'P101'). - **paytype** (string) - The type of payment (e.g., 'VISA'). - **rescode** (string) - Response code, '0000' indicates success. #### Response Example ``` ...&paymethod=P101&paytype=VISA&rescode=0000... ``` ``` -------------------------------- ### Fraud Detection (DecisionManager) API Source: https://context7.com/thanhnguyen162003/eximbay-docs/llms.txt Performs automatic real-time fraud screening using configurable risk rules. It returns one of three decisions: ACCEPT, REJECT, or REVIEW. ```APIDOC ## POST /Gateway/BasicProcessor.krp ### Description Initiates a payment transaction with fraud detection enabled. The system analyzes the transaction in real-time and returns a decision on whether to accept, reject, or flag it for review. ### Method POST ### Endpoint `https://secureapi.eximbay.com/Gateway/BasicProcessor.krp` ### Parameters #### Query Parameters - **ver** (string) - Required - API version. - **mid** (string) - Required - Merchant ID. - **txntype** (string) - Required - Transaction type (e.g., 'PAYMENT'). - **ref** (string) - Required - Merchant's order reference number. - **cur** (string) - Required - Transaction currency. - **amt** (number) - Required - Transaction amount. - **buyer** (string) - Required - Buyer's name. - **email** (string) - Required - Buyer's email address. - **lang** (string) - Required - Language code. - **returnurl** (string) - Required - URL to redirect the user after the transaction. - **statusurl** (string) - Required - URL for receiving transaction status updates. - **item_1_productname** (string) - Optional - Name of the first item. - **item_1_quantity** (string) - Optional - Quantity of the first item. - **item_1_unitprice** (string) - Optional - Unit price of the first item. - **shipToFirstname** (string) - Optional - Shipping recipient's first name. - **shipToLastname** (string) - Optional - Shipping recipient's last name. - **shipToPhone** (string) - Optional - Shipping recipient's phone number. - **shipToPostalcode** (string) - Optional - Shipping recipient's postal code. - **shipToState** (string) - Optional - Shipping recipient's state/province. - **shipToStreet** (string) - Optional - Shipping recipient's street address. - **shipToCity** (string) - Optional - Shipping recipient's city. - **shipToCountrycode** (string) - Optional - Shipping recipient's country code. - **billToFirstname** (string) - Optional - Billing recipient's first name. - **billToLastname** (string) - Optional - Billing recipient's last name. - **billToPostalcode** (string) - Optional - Billing recipient's postal code. - **billToState** (string) - Optional - Billing recipient's state/province. - **billToStreet** (string) - Optional - Billing recipient's street address. - **billToCity** (string) - Optional - Billing recipient's city. - **billToCountrycode** (string) - Optional - Billing recipient's country code. - **displaytype** (string) - Optional - Display type. - **fgkey** (string) - Required - Security hash of the request parameters. ### Request Example ``` ver=230&mid=YOUR_MID&txntype=PAYMENT&ref=ORD20221122006&cur=USD&amt=500.00&buyer=Test+Buyer&email=test@example.com&lang=EN&returnurl=https://yoursite.com/return&statusurl=https://yoursite.com/callback&item_1_productname=Electronics&item_1_quantity=1&item_1_unitprice=500.00&shipToFirstname=Test&shipToLastname=Buyer&shipToPhone=1234567890&shipToPostalcode=12345&shipToState=CA&shipToStreet=123+Test+St&shipToCity=Los+Angeles&shipToCountrycode=US&billToFirstname=Different&billToLastname=Person&billToPostalcode=54321&billToState=NY&billToStreet=789+Other+Ave&billToCity=New+York&billToCountrycode=US&displaytype=P&fgkey=GENERATED_SHA256_HASH ``` ### Response #### Success Response (200) - **ver** (string) - API version. - **mid** (string) - Merchant ID. - **txntype** (string) - Transaction type. - **ref** (string) - Merchant's order reference number. - **cur** (string) - Transaction currency. - **amt** (number) - Transaction amount. - **transid** (string) - Eximbay's transaction ID. - **rescode** (string) - Response code. - **resmsg** (string) - Response message. - **dm_decision** (string) - Fraud detection decision (ACCEPT, REJECT, REVIEW, ERROR). - **dm_review** (string) - Details for REVIEW decision (e.g., VC-ADDR-BM,VC-NEW-VEL). - **resdt** (string) - Response date and time. - **fgkey** (string) - Security hash of the response parameters. #### Response Example ``` ver=230&mid=YOUR_MID&txntype=PAYMENT&ref=ORD20221122006&cur=USD&amt=500.00&transid=TRANS_DM_123456789&rescode=0000&resmsg=Transaction+approved&dm_decision=REVIEW&dm_review=VC-ADDR-BM,VC-NEW-VEL&resdt=20221122171530&fgkey=RESPONSE_SHA256_HASH ``` ### DM Decision Values - **ACCEPT**: Transaction approved, low fraud risk. - **REJECT**: Transaction declined, high fraud risk (transaction not processed). - **REVIEW**: Manual review required (transaction processed but flagged). - **ERROR**: DM service error. ```