Maestro International
Payment Process | Integration | ||
---|---|---|---|
Authorization | ✔️ | Payment Page | ✔️ |
Deferred Settlement | ✔️ | Split Mode | ✔️ |
Refund | ✔️ | Mobile SDK | ✔️ |
Cancel | ✔️ | ||
Alias | ✔️ |
Description
Maestro is an international debit card service from Mastercard International. In various countries one can also pay with the Maestro-Card on the internet, but not yet in Switzerland. The type of payment can only be activated with an appropriate acquiring contract.
Web payment flow
Server to Server API calls
After a transactionId or alias was received by completing the payment flow on the web, the following server to server API calls can be used to do other actions.
Authorization
Request
curl -v -X POST https://api.sandbox.datatrans.com/upp/jsp/XML_authorize.jsp \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d @- << EOF
<?xml version="1.0" encoding="UTF-8" ?>
<authorizationService version="6">
<body merchantId="1000011011">
<transaction refno="749532">
<request>
<amount>100</amount>
<currency>CHF</currency>
<aliasCC>10263671026287183</aliasCC>
<expm>12</expm>
<expy>21</expy>
<sign>30916165706580013</sign>
</request>
</transaction>
</body>
</authorizationService>
EOF
Response
<?xml version='1.0' encoding='UTF-8'?>
<authorizationService version='6'>
<body merchantId='1000011011' status='accepted'>
<transaction refno='749532' trxStatus='response'>
<request>
<amount>100</amount>
<currency>CHF</currency>
<aliasCC>10263671026287183</aliasCC>
<expm>12</expm>
<expy>21</expy>
<sign>30916165706580013</sign>
<reqtype>NOA</reqtype>
</request>
<response>
<responseCode>01</responseCode>
<responseMessage>Authorized</responseMessage>
<uppTransactionId>180830114707269648</uppTransactionId>
<authorizationCode>707319649</authorizationCode>
<acqAuthorizationCode>114707</acqAuthorizationCode>
<maskedCC>675900xxxxxx0018</maskedCC>
</response>
</transaction>
</body>
</authorizationService>
Settlement
Request
curl -v -X POST https://api.sandbox.datatrans.com/upp/jsp/XML_processor.jsp \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d @- << EOF
<?xml version="1.0" encoding="UTF-8" ?>
<paymentService version="2">
<body merchantId="1000011011">
<transaction refno="705824">
<request>
<amount>100</amount>
<currency>CHF</currency>
<uppTransactionId>180830114707269648</uppTransactionId>
</request>
</transaction>
</body>
</paymentService>
Response
<?xml version='1.0' encoding='UTF-8'?>
<paymentService version='2'>
<body merchantId='1000011011' status='accepted'>
<transaction refno='705824' trxStatus='response'>
<request>
<amount>100</amount>
<currency>CHF</currency>
<uppTransactionId>180830114707269648</uppTransactionId>
<reqtype>COA</reqtype>
<transtype>05</transtype>
</request>
<response>
<responseCode>01</responseCode>
<responseMessage>settlement succeeded</responseMessage>
</response>
</transaction>
</body>
</paymentService>
Credit
Request
curl -v -X POST https://api.sandbox.datatrans.com/upp/jsp/XML_processor.jsp \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d @- << EOF
<?xml version="1.0" encoding="UTF-8" ?>
<paymentService version="2">
<body merchantId="1000011011">
<transaction refno="999273">
<request>
<amount>100</amount>
<currency>CHF</currency>
<uppTransactionId>180830114707269648</uppTransactionId>
<transtype>06</transtype>
</request>
</transaction>
</body>
</paymentService>
Response
<?xml version='1.0' encoding='UTF-8'?>
<paymentService version='2'>
<body merchantId='1000011011' status='accepted'>
<transaction refno='999273' trxStatus='response'>
<request>
<amount>100</amount>
<currency>CHF</currency>
<uppTransactionId>180830114707269648</uppTransactionId>
<transtype>06</transtype>
<reqtype>COA</reqtype>
</request>
<response>
<responseCode>01</responseCode>
<responseMessage>credit succeeded</responseMessage>
<uppTransactionId>180830114707269648</uppTransactionId>
<authorizationCode>206224339</authorizationCode>
<acqAuthorizationCode>183206</acqAuthorizationCode>
</response>
</transaction>
</body>
</paymentService>
Cancel
Request
curl -v -X POST https://api.sandbox.datatrans.com/upp/jsp/XML_processor.jsp \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d @- << EOF
<?xml version="1.0" encoding="UTF-8" ?>
<paymentService version="2">
<body merchantId="1000011011">
<transaction refno="29023">
<request>
<amount>100</amount>
<currency>CHF</currency>
<uppTransactionId>180830114707269648</uppTransactionId>
<reqtype>DOA</reqtype>
</request>
</transaction>
</body>
</paymentService>
Response
<?xml version='1.0' encoding='UTF-8'?>
<paymentService version='2'>
<body merchantId='1000011011' status='accepted'>
<transaction refno='29023' trxStatus='response'>
<request>
<amount>100</amount>
<currency>CHF</currency>
<uppTransactionId>180830114707269648</uppTransactionId>
<reqtype>DOA</reqtype>
<transtype>05</transtype>
</request>
<response>
<responseCode>01</responseCode>
<responseMessage>cancellation succeeded</responseMessage>
</response>
</transaction>
</body>
</paymentService>
Status
Request
curl -v -X POST https://api.sandbox.datatrans.com/upp/jsp/XML_status.jsp \
-H 'Content-Type: application/xml' \
-H 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
-d @- << EOF
<?xml version="1.0" encoding="UTF-8" ?>
<statusService version="5">
<body merchantId="1000011011">
<transaction>
<request>
<uppTransactionId>180830114707269648</uppTransactionId>
<reqtype>STX</reqtype>
</request>
</transaction>
</body>
</statusService>
Response
<?xml version='1.0' encoding='UTF-8'?>
<statusService version='5'>
<body merchantId='1000011011' status='accepted'>
<transaction trxStatus='response'>
<request>
<uppTransactionId>180830114707269648</uppTransactionId>
<reqtype>STX</reqtype>
</request>
<response itemNr='1'>
<responseCode>6</responseCode>
<responseMessage>DOA Cancel</responseMessage>
<refno>999273</refno>
<amount>1000</amount>
<currency>CHF</currency>
<authorizationCode>900053308</authorizationCode>
<pmethod>MAI</pmethod>
<uppTransactionId>180830114707269648</uppTransactionId>
<maskedCC>675900xxxxxx0018</maskedCC>
<aliasCC>10263671026287183</aliasCC>
<expm>12</expm>
<expy>21</expy>
<trxDate>20180830</trxDate>
<trxTime>182900</trxTime>
<trtype>05</trtype>
<settledAmount>100</settledAmount>
</response>
</transaction>
</body>
</statusService>
Updated over 2 years ago