Process Batch Response

After a batch has completed processing, you can request a response file that contains the result of each of the uploaded operations. You will receive the response file in csv format and in the same encoding as the batch upload request.

Download the Batch Response

You can download the batch response by sending a HTTPS GET request to:<versionNum>/merchant/<merchantId>/batch/<batchName>/response


  • <versionNum> is the version of Batch
  • <merchantId> is your Merchant identifier
  • <batchName> is your unique name for the batch

The response file will contain the same header and records as the original batch submission, with all fields overwritten with the results from the API request.

Below is an extract of a sample batch response file in csv format showing gateway response code as "APPROVED".


Using the Batch Response

The information provided in the batch response is based on the parameters defined in the batch upload request. You may find it useful to include parameters such as response.gatewayCode and error.cause to be able to identify problems in processing operations.

It is also a good practice to validate whether the data you supplied for an operation is the same data used to process the operation. For example, you should check that amount returned in the batch response for an operation matches the value you sent in the batch request for that operation.

Copyright © 2023 Mastercard