Hi, I received some codes from Bank which we will integrate to our website.
So here is the document which they sent to us.
Transaction registration
Request
Test system:
http://test.millikart.az:8513/gateway/payment/register?
mid=Test&amount=5025¤cy=944&description=test1000&reference=T7D3EDB885A5BC3C&language=az&signature=9A9E510BE7094D94284F1AFFE00FA4DA
OR
https://test.millikart.az:7444/gateway/payment/register?
mid=Test&amount=5025¤cy=944&description=test1000&reference=T7D3EDB885A5BC3C&language=az&
signature=9A9E510BE7094D94284F1AFFE00FA4DA
Production system:
https://pay.millikart.az/gateway/payment/register?
mid=Test&amount=5025¤cy=944&description=test1000&reference=T7D3EDB885A5BC3C&language=az&signature=9A9E510BE7094D94284F1AFFE00FA4DA
Parameters
<p><strong><span style="font-family:tahoma, sans-serif;">Name</span></strong></p>
<p><strong><span style="font-family:tahoma, sans-serif;">Description</span></strong></p>
<p><span style="font-family:tahoma, sans-serif;">Mid</span></p>
<p><span style="font-family:tahoma, sans-serif;">Merchant ID</span></p>
<p><span style="font-family:tahoma, sans-serif;">Amount</span></p>
<p><span style="font-family:tahoma, sans-serif;">Transaction amount (Integer: $50.25 = 5025)</span></p>
<p><span style="font-family:tahoma, sans-serif;">Currency</span></p>
<p><span style="font-family:tahoma, sans-serif;">Transaction currency code (ISO 4217) </span></p>
<p><span style="font-family:tahoma, sans-serif;">Description</span></p>
<p><span style="font-family:tahoma, sans-serif;">Transaction description (Can be used for item assigenment)</span></p>
<p><span style="font-family:tahoma, sans-serif;">Reference</span></p>
<p><span style="font-family:tahoma, sans-serif;">Transaction reference (unique transaction value set by merchant)</span></p>
<p><span style="font-family:tahoma, sans-serif;">Language</span></p>
<p><span style="font-family:tahoma, sans-serif;">Language</span></p>
<p><span style="font-family:tahoma, sans-serif;">Signature</span></p>
<p><span style="font-family:tahoma, sans-serif;">MD5 hash of concatenated parameter length + value with secret key</span></p>
<p> </p>
Signature example
$signature = Strtoupper(md5(strlen($mid).$mid.strlen($amount).$amount.strlen($currency).$currency.(!empty($description)? strlen($description).$description :"0").strlen($reference).$reference.strlen($language).$language.$key));
Strtoupper – is PHP function
Important: Signature value must be in upper case
“$key†value is given by Millikart and is sent by email as attachment in encrypted WinZip folder.
Example of $signature:
Mid = Test; amount = 5025; currency = 944; description = test1000; reference = T7D3EDB885A5BC3C; language = az;
Secret key = 9A9E510BE7094D94284F1AFFE00FA4DA
$signature= Strtoupper(md5(4test4502539448test100016T7D3EDB885A5BC3C2az9A9E510BE7094D94284F1AFFE00FA4DA));
Response:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<response>
<redirect>
https://85.132.61.113:7444/ecomm2/ClientHandler?trans_id=NCxdwVAgsducuvsjTN6AAHud3w=
</redirect>
<code>0</code>
<description>OK</description>
</response>
if you want to go directly to the payment page, add the end of the request redirect=1
default redirect=0
Example:
http://test.millikart.az:8513/gateway/payment/register?
mid=Test&amount=5025¤cy=944&description=test1000&reference=T7D3EDB885A5BC3C&language=az&signature=055ccfa78337f1d876aba14d6f64c2df&redirect=1
OR
https://test.millikart.az:7444/gateway/payment/register?
mid=Test&amount=5025¤cy=944&description=test1000&reference=T7D3EDB885A5BC3C&language=az&
signature=055ccfa78337f1d876aba14d6f64c2df&redirect=1
Merchant callback URL
Each merchant has a callback URL which is called after transaction is complete in the following way
http://callback.url/?reference=test1000
Merchant needs to check transaction status the way described below
Transaction status
Request
Test system
http://test.millikart.az:8513/gateway/payment/status?mid=test&reference=T7D3EDB885A5BC3C
OR
https://test.millikart.az:7444/gateway/payment/status?mid=test&reference=T7D3EDB885A5BC3C
Production system
https://pay.millikart.az/gateway/payment/status?mid=test&reference=T7D3EDB885A5BC3C
Parameters
<p><strong><span style="font-family:tahoma, sans-serif;">Name</span></strong></p>
<p><strong><span style="font-family:tahoma, sans-serif;">Description</span></strong></p>
<p><span style="font-family:tahoma, sans-serif;">Mid</span></p>
<p><span style="font-family:tahoma, sans-serif;">Merchant ID</span></p>
<p><span style="font-family:tahoma, sans-serif;">Reference</span></p>
<p><span style="font-family:tahoma, sans-serif;">Transaction reference (unique transaction value set by merchant)</span></p>
<p> </p>
Response:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<response>
<amount>5025</amount>
<currency>944</currency>
<payment-description> test1000</payment-description>
<reference>T7D3EDB885A5BC3C7232</reference>
<timestamp>20130923113517</timestamp>
<xid>57w0n8N24mAtMm+GAgYuHW0zuCk=</xid>
<rrn>424715434469</rrn>
<approval>330002</approval>
<pan>402865******8101</pan>
<RC>000</RC>
<code>0</code>
<description>Ok</description>
</response>
In this XML response <RC>response code </RC> is transaction response code<RC>response code </RC> .
RC is the answer of the issuer bank.
Descriptions of the transaction response codes
000 - Successful transaction
101 - Decline, expired card
119 - Decline, transaction not permitted to cardholder
100 - Decline (general, no comments)
Descriptions of the <code></code>:
Code = -1 ; description = Unknown
Code = 0 ; description = OK
Code = 1 ; description = Failed
Code = 2 ; description = Created
Code = 3 ; description = Pending
Code = 4 ; description = Declined
Code = 5 ; description = Reversed
Code = 7 ; description = Timeout
Code = 9 ; description = Cancelled
Code = 10 ; description = Returned
Code = 11 ; description = Active
Code = 12 ; description = Attempt
Code = 13 ; description = Pending3DS
BIN parameters for transaction
If you include parameter in the reference field, that bin will be shown in a payment page automatically.
Example: http://test.millikart.az:8513/gateway/payment/register?
mid=Test&amount=5025¤cy=944&description=test1000&reference=bin:402865T7D3EDB885A5BC3C&language=az&signature=055ccfa78337f1d876aba14d6f64c2df
If you wish to use this option, you must notify us
Could someone help me in this process?