Skip to main content

Payment Flow

Step by Step Guide for Payment Flow

  1. User selects the item and creates a cart on the merchant site. User presses on proceed to pay cta in merchant m-site.
  2. Merchant Server calls Initiate Transaction API to Synapse Server. The request contains
    1. cart metadata for the cart created on the m-site.
    2. the total payable amount, merchant payment reference Id and merchant order id.
    3. callback URL of Merchant Server, to receive a callback from Synapse Server after payment completion.
  3. Synapse Server stores cart metadata passed by Merchant Server. In response, Synapse Server sends a payload that contains the synapse payment reference id.
  4. Merchant Server passes payload to the Merchant App.
  5. Merchant App calls Initiate Synapse Payment JS API to transfer control to Synapse App. The request contains the payload received from Merchant Server.
  6. Synapse App sends the payload to Synapse Server.
  7. Synapse Server uses the synapse payment reference id received in payload from Synapse App to map cart metadata received in InitiatePayment Request (Step 2) with the user.
  8. Synapse App transfers the control to Partner App to display various payment modes.
  9. User completes payment on the Partner App.
  10. Synapse Server gets the final payment status from Partner Server in an S2S API call.
  11. Synapse Server initiates S2S callback to the merchant once payment reaches any terminal state. A callback URL must be sent in the Initiate Transaction Request API (Step 2) for merchants to receive this callback.
  12. If the callback URL is shared, Merchant Server receives final payment status as a callback. Merchant can then proceed with order fulfilment.
  13. Partner App transfers control to Synapse App after payment completion.
  14. Synapse App calls Synapse Server for merchant payment payload.
  15. The merchant payment payload consists of the merchant payment reference id received in Initiate Payment Request(Step 2) in an encrypted format. Synapse server passes the merchant payment payload to Synapse App.
  16. Synapse app calls the Complete Synapse Payment callback JS API with merchant payment payload in request to transfer control to the merchant app.
  17. Merchant app opens the order detail screen and checks the transaction status.
  18. Merchant Server calls Payment Status API to get the final transaction status from Synapse Server.
  19. Synapse Server sends the status to the Merchant server.
  20. Merchant Server passes the status to the merchant app and proceeds with order fulfilment
  21. Displays the status to the user and proceeds with the flow.