Behpardakht Mellat Payment Gateway PGW User Manual English Ver 1.1
User Manual:
Open the PDF directly: View PDF .
Page Count: 11
Download | |
Open PDF In Browser | View PDF |
Behpardakht Mellat Co Behpardakht Payment Gateway User Guide: How to integrate with Behpardakht Payment Gateway Revision: 1.1 Revision: 1.1 Behpardakht Payment Gateway Date: May 2013 User Guide: How to integrate with Behpardakht Payment Gateway Index 1. 1.1 2. 2.1 2.2 2.3 2.4 2.4.1 2.4.2 2.4.3 2.4.4 2.4.5 2.5 2.6 Page 1 Introduction ......................................... 2 Scope .......................................... 2 Method description in payment flow ......................... 2 Prerequisites ...................................... 2 How to use Web Service ............................... 3 Methods Parameter .................................. 3 Methods Description ................................. 4 bpPayRequest method ............................... 4 bpVerifyRequest method .............................. 6 bpSettleRequest method .............................. 6 bpInquiryRequest method ............................. 7 bpReversalRequest method ............................ 8 Return Parameter ................................... 9 Response code descriptions ............................ 9 Behpardakht Mellat Co Revision: 1.1 Behpardakht Payment Gateway Date: May 2013 User Guide: How to integrate with Behpardakht Payment Gateway 1. Introduction Mellat Bank Payment Gateway enables internet merchants to accept online payments via cards accepted by Shetab network. Mellat Bank Payment Gateway provides secure and simple means of authorizing Shetab card transactions and takes complete responsibility for the online transaction, including the collection of card details. Mellat Bank Payment Gateway uses web service technology over SSL secure link to expose payment services to merchants. This use the basic web services platform for transferring data in XML + HTTPS. The advantage of using Web Services for publishing payment services is that Web Services are found and used through the web and merchants can use an ecommerce engine with any programming language to integrate with it. Behpardakht has provided sample clients for main programming language to make it easy for merchants to have online payment in their websites. 1.1 Scope This document explains how your website should communicate Mellat Bank Payment Gateway, goes on to explain how to integrate with our live environments, and contains the complete Payment Protocol. 2. Method description in payment flow 2.1 Prerequisites IP addresses of Merchant host should be officially informed to Mellat Bank to give privilege to access payment gateway services. Merchants should make sure to have port 443 and 80 open in their host. Page 2 Behpardakht Mellat Co Revision: 1.1 Behpardakht Payment Gateway Date: May 2013 User Guide: How to integrate with Behpardakht Payment Gateway 2.2 How to use Web Service WSDL (Web Services Description Language) is an XML-based language for describing Web services and how to access them. Mellat Bank Payment Gateway WSDL is accessible with the following links. Operational Server: https://bpm.shaparak.ir/pgwchannel/services/pgw?wsdl 2.3 Methods Parameter Parameters which merchant should pass in calling methods or getting them back in return are as following: 1. terminalId: Merchant terminal number 2. userName: Merchant terminal username 3. userPassword: Merchant terminal password 4. amount: Transaction amount 5. localDate: Merchant local date 6. localTime: Merchant local time 7. additionalData: Some Additional data to keep for this transaction 8. callBackUrl: Callback URL of merchant which the customer will be redirected back after payment accomplished. 9. payerId: Merchant Payer ID 10. orderId: Merchant should provide a number for each new payment transaction too keep track of final payment status. This number must be unique in calling bpPayRequest and bpRefundRequest. Page 3 Behpardakht Mellat Co Revision: 1.1 Behpardakht Payment Gateway Date: May 2013 User Guide: How to integrate with Behpardakht Payment Gateway 11. saleOrderId: To distinguish between method calls, merchant can send a unique orderId in consequence method calls after bpPayRequest or bpRefundRequest. 12. saleReferenceId: This is a unique number generated for successful sales by Mellat Bank Payment Gateway and must be used as main transaction identifier in consequence method calls. Note: All parameter names are case-sensitive 2.4 Methods Description Mellat Bank Payment Gateway publishes 8 methods, which the first 3 ones are building the core elements of online payment flow and the remained 5 methods will be handy in special cases. 2.4.1 bpPayRequest method This method is called by merchant to initial a payment transaction. In this step, terminal and transaction validity will be controlled and if terminal is authorize by the Mellat Bank Payment Gateway, a unique encrypted hash reference number will be generated and sent back in return which Merchant site should use it to redirect customer to Mellat Bank Payment Gateway site. This method will return a string as a result which in case of an error, it will include relevant response code, otherwise it will include a zero as approved response code plus a second part which will be the encrypted hash reference number. Example: 0, AF82041a2Bf6989c7fF9 The two values are comma separated. The first part is the response code (for more information, see table 10) The second part is an encrypted hash reference number which should be post to Mellat Bank Payment Gateway when redirecting customer to. Page 4 Behpardakht Mellat Co Revision: 1.1 Behpardakht Payment Gateway Date: May 2013 User Guide: How to integrate with Behpardakht Payment Gateway The URL which the encrypted hash reference number should be posted to is as following: Operational Server: https://bpm.shaparak.ir/pgwchannel/startpay.mellat Row Parameter Name Example Description Type terminalId 1234 Merchant Terminal Identifier long userName “User” Merchant Username string 3 userPassword “******” Merchant Password string 4 orderId 10 Order Identifier long 5 amount 1 Order Amount long 6 localDate “20101008” Merchant Local Date string 7 localTime "102003" Merchant Local Time string “Have 3 items in Any text with 1000 characters basket” limit “http://www.mysite.com/ The Merchant URL which myfolder/callbackmellat. customer will be redirected to aspx” at the end. 0 Payer Identifier 1 2 8 additionalData 9 callBackUrl 10 payerId string string long Table1: bpPayRequest Input parameters description Note: Order Id should be unique in each pay request call. Note: Use your site domain address instead of IP address in callBackUrl. Note: encrypted hash reference number value is case-sensitive. Note: Merchants who have payer Id in theirs bank account, can pass the correct value in pay request call, otherwise, you must pass “0” as default value. Page 5 Behpardakht Mellat Co Revision: 1.1 Behpardakht Payment Gateway Date: May 2013 User Guide: How to integrate with Behpardakht Payment Gateway 2.4.2 bpVerifyRequest method When card holder made payment transaction in Mellat Bank Payment Gateway site, some information including ResCode and SaleReferenceId will be posted back to merchant and then merchant should confirm payment transaction by calling bpVerifyRequest method and passing the following parameters to: Row Parameter Name Example Description Type terminalId 1234 Merchant Terminal Identifier long userName “User” Merchant Username string 3 userPassword “******” Merchant Password string 4 orderId 11 Order Identifier long saleOrderId 10 saleReferenceId 5142510 1 2 5 6 orderId of pay request (Original Order identifier) saleReferenceId returned in pay request long long Table2: bpVerifyRequest Input parameters description Note: The Return Value of this method call will be a string which shows the verify request result (See table 10 for the list of response codes). Note: Merchants should display the right message in their site according to returned ResCode. Note: If Merchant doesn’t verify payment transaction after 15 minutes, the payment transaction will be reversed automatically by Mellat Bank Payment Gateway and the money will be charged back to card holder. 2.4.3 bpSettleRequest method Merchant can settle payment transactions which already were verified successfully at any time by calling bpSettleRequest an passing the following parameters: Page 6 Behpardakht Mellat Co Revision: 1.1 Behpardakht Payment Gateway Date: May 2013 User Guide: How to integrate with Behpardakht Payment Gateway Row Parameter Name Example Description Type terminalId 1234 Merchant Terminal Identifier long userName “User” Merchant Username string 3 userPassword “******” Merchant Password string 4 orderId 12 Order Identifier long saleOrderId 10 saleReferenceId 5142510 1 2 5 6 orderId of pay request (Original Order identifier) saleReferenceId returned in pay request long long Table3: bpSettleRequest Input parameters description Note: The Return Value of this method call will be a string which shows the settle request result (See table 10 for the list of response codes). Note: Merchants should call settle request method to release the payment transaction and transfer payment amount to their bank account. 2.4.4 bpInquiryRequest method Merchant can get status of verify request (sale and it's verify) at any time by calling bpInquiryRequest method and passing the following parameters to: Row Parameter Name Example Description Type terminalId 1234 Merchant Terminal Identifier long userName “User” Merchant Username string 3 userPassword “******” Merchant Password string 4 orderId 13 Order Identifier long saleOrderId 10 1 2 5 Page 7 Behpardakht Mellat Co orderId of pay request (Original Order identifier) long Revision: 1.1 Behpardakht Payment Gateway Date: May 2013 User Guide: How to integrate with Behpardakht Payment Gateway 6 saleReferenceId 5142510 saleReferenceId returned in pay request long Table4: bpInquiryRequest Input parameters description Note: The Return Value of this method call will be a string which shows the inquiry request result (See table 10 for the list of response codes). Note: Merchants should just call this method when it is not aware of verify request for any reason. 2.4.5 bpReversalRequest method If Merchants decided to not deliver products or services to card holders till current working day, they can cancel the payment transaction and charge back the cardholder with the order amount by calling bpReversalRequest method and passing the following parameters: Row Parameter Name Example Description Type terminalId 1234 Merchant Terminal Identifier long userName “User” Merchant Username string 3 userPassword “******” Merchant Password string 4 orderId 14 Order Identifier long saleOrderId 10 saleReferenceId 5142510 1 2 5 6 orderId of pay request (Original Order identifier) saleReferenceId returned in pay request long long Table5: bpReversalRequest Input parameters description Note: The Return Value of this method call will be a string which shows the reversal request result (See table 10 for the list of response codes). Note: Merchants can just reverse not settled payment transaction till 2 hours after the pay transaction by calling reversal request method. Page 8 Behpardakht Mellat Co Revision: 1.1 Behpardakht Payment Gateway Date: May 2013 User Guide: How to integrate with Behpardakht Payment Gateway 2.5 Return Parameter The following parameters posted back to merchant call back URL after payment transaction by Mellat Bank Payment Gateway: Row 1 2 3 4 Parameter Name Example Description Type RefId AF82041a2Bf689c7fF9 Merchant Terminal Identifier long ResCode Merchant Username string 0 SaleOrderId 10 SaleReferenceId 5142510 Sale reference Id C9086F2AACF739F7D Encrypted information of card 50ACC9FDC60C53E81 0FB9135723D256732C holder (One way encrypted orderId of pay request 5 CardHolderInfo (Original Order identifier) PAN) E4D1E2E409F7 Table9: Return parameters posted to merchant callback URL 2.6 Response code descriptions Response Code 0 11 12 13 14 15 16 17 18 19 111 112 113 114 21 23 Page 9 Description Transaction Approved Invalid Card Number No Sufficient Funds Incorrect Pin Allowable Number Of Pin Tries Exceeded Card Not Effective Exceeds Withdrawal Frequency Limit Customer Cancellation Expired Card Exceeds Withdrawal Amount Limit No Such Issuer Card Switch Internal Error Issuer Or Switch Is Inoperative Transaction Not Permitted To Card Holder Invalid Merchant Security Violation Behpardakht Mellat Co string long string Revision: 1.1 Behpardakht Payment Gateway Date: May 2013 User Guide: How to integrate with Behpardakht Payment Gateway 24 25 31 32 33 34 35 41 42 43 44 45 46 47 48 49 412 413 414 415 416 417 418 419 421 51 54 55 61 Invalid User Or Password Invalid Amount Invalid Response Format Error No Investment Account System Internal Error Invalid Business Date Duplicate Order Id Sale Transaction Not Found Duplicate Verify Verify Transaction Not Found Transaction Has Been Settled Transaction Has Not Been Settled Settle Transaction Not Found Transaction Has Been Reversed Refund Transaction Not Found Bill Digit Incorrect Payment Digit Incorrect Bill Organization Not Valid Session Timeout Data Access Exception Payer Id Is Invalid Customer Not Found Try Count Exceeded Invalid IP Duplicate Transmission Original Transaction Not Found Invalid Transaction Error In Settle Table 10: Response code description Page 10 Behpardakht Mellat Co
Source Exif Data:
File Type : PDF File Type Extension : pdf MIME Type : application/pdf PDF Version : 1.5 Linearized : No Page Count : 11 Language : en-US Tagged PDF : Yes Title : Behpardakht Mellat - Payment Gateway Author : Analysis & Design Team Subject : Behpardakht Payment Gateway Creator : Microsoft® Office Word 2007 Create Date : 2014:05:04 10:18:40+03:30 Modify Date : 2014:05:04 10:18:40+03:30 Producer : Microsoft® Office Word 2007EXIF Metadata provided by EXIF.tools