Happy Business Starts Here

How to batch settle payments through API?

Highlighted
Support SME

How to batch settle payments through API?

Please make sure to first test in the Sandbox environment before making any change to the Production environment.

 

1. Prepare the list of payments to need to be updated

If you'd like to settle all payments with Submitted as GatewaState, it could be done through Data Source Export:

Screen Shot 2020-02-05 at 10.33.15 PM.png

open the exported file, copy all the records and paste into a text editor, update the 1st line from "Payment: ID" to "ID"

save from the text editor with encoding LF

saveCSV.gif

 

2. Use REST API client tool for bulk operation

Many of the REST API client tools(e.g. Postman) have the feature to help customers execute REST API requests in bulk.

1) create an update request under a collection, make payment id in the URL to be input params

Screen Shot 2020-02-05 at 11.37.38 PM.png

I've left the request body as {} since no param is required, but please add the ones needed according to the API reference here for API request: Settle Payment

2) start Postman's Collection Runner and select the Collection where your request is saved, select the file generated from 1 to be the Data File, start run

collectionRunner.gif

 

 

Reference:

Starting a collection run

Looping through a data file in the Postman Collection Runner






If you found my answer helpful, please give me a kudo ↑
Help others find answers faster by accepting my post as a solution √