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 website and the Swish app, providing a seamless and native user experience.

Indirect redirection

This method redirects users merchant website to the Swish app and then back to merchant website, with a brief transition through the browser.

Summarised view is as follows:

DimensionDirect redirectionIndirect redirection
Suitable forLarge businessSmall to medium sized business
User ExperienceSuperior and seamlessNot Smooth
Consumer ExperienceExcellentGood
Development effortSignificantMinimal
Transaction Status updatePolled by MerchantPublished 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. Indirect redirection is supported for merchant websites on mobile devices but not for merchant mobile apps.

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

When consumer starts from the merchant app, the only supported integration is direct redirection.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

  1. The consumer selects Swish as their preferred payment method on merchant app.
  2. The consumer is routed to Swish app where they are required to enter the desired details, authorise and complete the transaction.
  3. The consumer is routed back to merchant app on mobile device directly after completing the transaction
  4. The merchant receives the payment confirmation
  5. The merchant ships the order/deliver the goods to the consumer.

Specific input parameters for the TRANSACTION call

Field NameM/O/CTypeRegexDescription
merchantredirecturiMstringN/AMerchant App URI where consumer will be redirected after authorising the payment.
dynamicdescriptorOstringN/ADescription of the order

Specific output parameters for the TRANSACTION call

Field NameM/O/CTypeRegexDescription
qrpayloadOstringN/ATo generate the QR code image, use the QR payload and follow Swish guidelines.

Transient output parameters for the TRANSACTION call

Field NameM/O/CTypeRegexDescription
appintenturiMstringN/ASwish AppIntent URI that has callback parameter , that helps to navigate to merchant app once payment is successful routing through browser.
qrcodeOstringN/AThis is not to be considered in this flow.

TRANSACTION call input

tag=swish
&txtype=TRANSACTION
&countrycode=SE
&preferredlanguage=en
&currency=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//
&notificationurl=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
&RAND3874536273=f8234430721f1a7ef4a4462de71dfd1d
&REDIRECTSECRET=dcn94nd2oud8eedhg38dkhed
&REDIRECTURL=https://r3.public.k8s.qa.ppro.com/swish/T/I?tx=10&rs=3ZTw&cs=0b3cb24merchant system needs to skip this field for Merchant App to Swish App Flow//
&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 the "TRANSIENTOUT.APPINTENTURI" from the successful transaction response to initiate the redirection to the Swish app.

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, there is a flexibility to choose between direct and indirect integration methods.

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

  1. The consumer selects Swish as their preferred payment method on merchant website
  2. The consumer is routed to Swish app where they are required to enter the desired details, authorise and complete the transaction.
  3. The consumer is routed back to merchant website on mobile device directly after completing the transaction
  4. The merchant receives the payment confirmation
  5. 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

  1. The consumer selects Swish as their preferred payment method
  2. The consumer is routed to Swish app where they are required to enter the desired details, authorise and complete the transaction.
  3. The consumer is routed back to merchant website via browser on mobile device after completing the transaction
  4. The merchant receives the payment confirmation
  5. The merchant ships the order/deliver the goods to the consumer.

Transaction details for both direct and indirect redirection

Specific input parameters for the TRANSACTION call

Field NameM/O/CTypeRegexDescription
merchantredirecturiMstringN/AMerchant Website URL where consumer will be redirected after authorising the payment.
dynamicdescriptorOstringN/ADescription of the order

Specific output parameters for the TRANSACTION call

Field NameM/O/CTypeRegexDescription
qrpayloadOstringN/ATo generate the QR code image, use the QR payload and follow Swish guidelines.

Transient output parameters for the TRANSACTION call

Field NameM/O/CTypeRegexDescription
appintenturiMstringN/ASwish AppIntent URI that has callback parameter , that helps to navigate to merchant app once payment is successful routing through browser.
qrcodeOstringN/AThis is not to be considered in this flow.

TRANSACTION call input

tag=swish
&txtype=TRANSACTION
&countrycode=SE
&preferredlanguage=en
&currency=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 website to Swish App Flow//
&notificationurl=https%3A%2F%2Fmerchant.com%2Fwork%2Fppro2%2Fnotification.php
&accountholdername=Tester+Doe
&specin.merchantredirecturi=https://amazon.com
&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
&RAND3874536273=f8234430721f1a7ef4a4462de71dfd1d
&REDIRECTSECRET=dcn94nd2oud8eedhg38dkhed
&REDIRECTURL=https://r3.public.k8s.qa.ppro.com/swish/T/I?tx=10&rs=3ZTw&cs=0b3cb24//Merchant system needs to skip this field for Merchant Website to Swish App Flow//
&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

For direct redirection, use the "TRANSIENTOUT.APPINTENTURI" from the successful transaction response to initiate the redirection to the Swish app.

For indirect redirection, use the "REDIRECTURL" provided in the successful transaction response to redirect the consumer to the Swish 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.