Swish M-Commerce
Allow consumers to pay via Swish by redirecting them from a merchant's website or mobile app to the Swish app. They should authorise the payment and then be redirected back to the merchant's website or mobile app.
Integration Methods
There are two integration methods for the m-commerce journey: direct and indirect redirection. Each option has its own benefits, and the choice should depend on your specific needs and available resources.
Direct redirection
This approach enables direct navigation between merchant app or merchant website on a mobile device and the Swish app, providing a seamless and native user experience.
Indirect redirection
This method redirects users from the merchant app or merchant website on a mobile device to the Swish app and then back to the merchant app or website, with a brief transition through the browser.
Summarised view is as follows:
Dimension | Direct redirection | Indirect redirection |
---|---|---|
Suitable for | Large business | Small to medium sized business |
User Experience | Superior and seamless | Not Smooth |
Consumer Experience | Excellent | Good |
Development effort | Significant | Minimal |
Transaction Status update | Polled by Merchant | Published by PPRO |
Our Recommendation
While both methods have their advantages, we recommend the direct redirection approach for merchants with the resources to implement it. This method offers a superior user experience, which can result in higher conversion rates and increased consumer satisfaction. However, if you are a small to medium-sized merchant seeking a quicker implementation with minimal development effort on your end, indirect redirection is a suitable choice.
Ultimately, the decision should be based on your specific business needs and development capabilities.
Consumer Entry Points
For the M-Commerce journey, the consumer's payment experience can begin either through the merchant's mobile app or website on their mobile device. Once initiated, the next step involves seamlessly routing the consumer to the Swish app to authorise and complete the payment.
The following section outlines the process for both of these starting points, ensuring a smooth and efficient payment flow for your customers.
Kickstarting from the Merchant App
In the direct redirection from the merchant app to the Swish app, the consumer is redirected directly to the Swish app to complete the payment and is then returned to the merchant app once the payment is authorised
Consumer Journey
- The consumer selects Swish as their preferred payment method on merchant app.
- The consumer is routed to Swish app where they are required to enter the desired details, authorise and complete the transaction.
- The consumer is routed back to merchant app on mobile device directly after completing the transaction
- The merchant receives the payment confirmation
- The merchant ships the order/deliver the goods to the consumer.
In the indirect redirection from the merchant app to the Swish app, the consumer is redirected to the Swish app to complete the payment and then returned to the merchant app via the browser once the payment is authorised
- The consumer selects Swish as their preferred payment method on merchant app.
- The consumer is routed to Swish app where they are required to enter the desired details, authorise and complete the transaction.
- The consumer is routed back to merchant app via browser after completing the transaction
- The merchant receives the payment confirmation
- The merchant ships the order/deliver the goods to the consumer.
Specific input parameters for the TRANSACTION call
Field Name | M/O/C | Type | Regex | Description |
---|---|---|---|---|
merchantredirecturi | M | string | N/A | Merchant app deeplink where consumer will be redirected after authorising the payment. |
dynamicdescriptor | O | string | N/A | Description of the order |
Specific output parameters for the TRANSACTION call
Field Name | M/O/C | Type | Regex | Description |
---|---|---|---|---|
qrpayload | O | string | N/A | To generate the QR code image, use the QR payload and follow Swish guidelines. |
Transient output parameters for the TRANSACTION call
Field Name | M/O/C | Type | Regex | Description |
---|---|---|---|---|
appintenturi | M | string | N/A | Swish AppIntent URI that has callback parameter , that helps to navigate to merchant app once payment is successful routing through browser. txid(id of the original transaction) and cs(checksum) are not present as query parameters in this attribute |
qrcode | O | string | N/A | This is not to be considered in this flow. |
TRANSACTION call input
tag=swish
&txtype=TRANSACTION
&countrycode=SE
&preferredlanguage=en
¤cy=SEK
&amount=250
&merchanttxid=84564142227
&login=johndoe
&password=wXBrpVporFVjGO4R
&contractid=JOHNDOETESTCONTRACT
&channel=testchannel
&merchantredirecturl=https://amazon.com//PPRO system will skip this field for Merchant App to Swish App Flow//
¬ificationurl=https%3A%2F%2Fmerchant.com%2Fwork%2Fppro2%2Fnotification.php
&accountholdername=Tester+Doe
&specin.merchantredirecturi=amzn://apps/orderID=AS4f?p=PQRE//
&specin.dynamicdescriptor=checkoutof2cakes
&returnmode=urlencodeext
For For standard input parameters, check Input parameters for the TRANSACTION call
TRANSACTION call output
When Transaction request is successful
&STATUS=PENDING
&TXID=10
&ERRMSG=
&TRANSIENTOUT.APPINTENTURI=swish://paymentrequest?token=AWQ&callbackurl=amzn://apps/orderID=AS4f?p=PQRE//Direct Redirection to merchant app//
&RAND3874536273=f8234430721f1a7ef4a4462de71dfd1d
&REDIRECTSECRET=dcn94nd2oud8eedhg38dkhed
&REDIRECTURL=https://r3.public.k8s.qa.ppro.com/swish/T/I?tx=10&rs=3ZTw&cs=0b3cb24//Redirection to merchant app via the browser//
&TRANSIENTOUT.QRCODE=PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGl //base 64 encoded string,merchant system needs to skip this field for Merchant App to Swish App Flow//
&CHANNEL=testchannel
&TAG=swish
&MERCHANTTXID=sale1002
&FUNDSSTATUS=NOT_EXPECTED
Note
Use "TRANSIENTOUT.APPINTENTURI" from the successful transaction response to initiate direct redirection to the Merchant app, and "REDIRECTURL" to redirect the consumer to the Merchant app via the browser.
When Transaction request is not successful
&STATUS=FAILED
&TXID=600520459
&ERRMSG=Remote%20System%20Error
&RAND3874536273=f8234430721f1a7ef4a4462de71dfd1d
&FAILREASON=REMOTE_ERROR
&CHANNEL=testchannel
&TAG=swish
&MERCHANTTXID=sale1002
&FUNDSSTATUS=NOT_EXPECTED
For standard output parameters, see Output parameters for the TRANSACTION call.
Kickstarting from the Merchant Website on mobile device
When consumer initiates from a merchant website on a mobile device, the only supported integration is direct redirection only.
In the direct redirection from the merchant website to the Swish app, the consumer is redirected to the Swish app to complete the payment and is then returned to the merchant website once the payment is authorised
Consumer Journey
- The consumer selects Swish as their preferred payment method on merchant website
- The consumer is routed to Swish app where they are required to enter the desired details, authorise and complete the transaction.
- The consumer is routed back to merchant website on mobile device directly after completing the transaction
- The merchant receives the payment confirmation
- The merchant ships the order/deliver the goods to the consumer.
In the indirect redirection from the merchant website to the Swish app, the consumer is redirected to the Swish app to complete the payment and then returned to the merchant website via the browser once the payment is authorised
Consumer Journey
- The consumer selects Swish as their preferred payment method on merchant website.
- The consumer is routed to Swish app where they are required to enter the desired details, authorise and complete the transaction.
- The consumer is routed back to merchant website via browser on mobile device after completing the transaction
- The merchant receives the payment confirmation
- The merchant ships the order/deliver the goods to the consumer.
Transaction details
Specific input parameters for the TRANSACTION call
Field Name | M/O/C | Type | Regex | Description |
---|---|---|---|---|
dynamicdescriptor | O | string | N/A | Description of the order |
Specific output parameters for the TRANSACTION call
Field Name | M/O/C | Type | Regex | Description |
---|---|---|---|---|
qrpayload | O | string | N/A | To generate the QR code image, use the QR payload and follow Swish guidelines. |
Transient output parameters for the TRANSACTION call
Field Name | M/O/C | Type | Regex | Description |
---|---|---|---|---|
appintenturi | M | string | N/A | Swish AppIntent URI that has callback parameter , that helps to navigate to merchant app once payment is successful routing through browser. |
qrcode | O | string | N/A | This is not to be considered in this flow. |
TRANSACTION call input
tag=swish
&txtype=TRANSACTION
&countrycode=SE
&preferredlanguage=en
¤cy=SEK
&amount=250
&merchanttxid=84564142227
&login=johndoe
&password=wXBrpVporFVjGO4R
&contractid=JOHNDOETESTCONTRACT
&channel=testchannel
&merchantredirecturl=https://amazon.com//The merchant website URL to which redirection should occur//
¬ificationurl=https%3A%2F%2Fmerchant.com%2Fwork%2Fppro2%2Fnotification.php
&accountholdername=Tester+Doe
&specin.dynamicdescriptor=checkoutof2cakes
&returnmode=urlencodeext
For For standard input parameters, check Input parameters for the TRANSACTION call
TRANSACTION call output
When Transaction request is successful
&STATUS=PENDING
&TXID=10
&ERRMSG=
&TRANSIENTOUT.APPINTENTURI=swish://paymentrequest?token=AWQ&callbackurl=amzn://apps/orderID=AS4f?p=PQRE//Direct Redirection to merchant website on mobile device//
&RAND3874536273=f8234430721f1a7ef4a4462de71dfd1d
&REDIRECTSECRET=dcn94nd2oud8eedhg38dkhed
&REDIRECTURL=https://r3.public.k8s.qa.ppro.com/swish/T/I?tx=10&rs=3ZTw&cs=0b3cb24//Redirection to merchant website on mobile device via the browser//
&TRANSIENTOUT.QRCODE=PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGl //base 64 encoded string,merchant system needs to skip this field for Merchant Website to Swish App Flow//
&CHANNEL=testchannel
&TAG=swish
&MERCHANTTXID=sale1002
&FUNDSSTATUS=NOT_EXPECTED
Note
Use "REDIRECTURL" from the successful transaction response to redirect the consumer to the merchant website on mobile device via the browser, and "TRANSIENTOUT.APPINTENTURI" to initiate direct redirection to the merchant website on mobile device.
When Transaction request is not successful
&STATUS=FAILED
&TXID=600520459
&ERRMSG=Remote%20System%20Error
&RAND3874536273=f8234430721f1a7ef4a4462de71dfd1d
&FAILREASON=REMOTE_ERROR
&CHANNEL=testchannel
&TAG=swish
&MERCHANTTXID=sale1002
&FUNDSSTATUS=NOT_EXPECTED
For standard output parameters, see Output parameters for the TRANSACTION call.
Updated 16 days ago