Skip to main content

Uploading and Confirming a Batch

Step-by-step guide to uploading a batch file, reviewing validation results, and confirming execution.

Written by Ryan O
Updated today

Overview

Once your batch file is prepared, the next steps are uploading it to Anton, reviewing the validation results, and confirming the batch to begin processing. This guide walks through each step using both the merchant portal and the API.

Step 1: Upload the Batch File

Via the Merchant Portal

Navigate to Batch Payouts and click New Batch. Drag and drop your CSV file or click to browse and select it. Anton processes the file and displays the validation results.

Via the API

Upload the file as a multipart form upload:

curl https://api.antonpayments.dev/v1/batches \
  -X POST \
  -H "Authorization: Bearer ak_test_..." \
  -F "[email protected]"

The response includes a summary of the upload:

  • id -- The batch ID for subsequent operations

  • status -- Set to pending_review

  • total_rows -- Number of rows parsed

  • valid_rows -- Rows that passed validation

  • error_rows -- Rows with validation errors

  • total_amount -- Sum of all valid row amounts

Step 2: Review Validation Results

After upload, review the validation summary. If there are errors, you can retrieve details:

curl https://api.antonpayments.dev/v1/batches/batch_abc123/errors \
  -H "Authorization: Bearer ak_test_..."

Each error includes the row number, the field that failed validation, and a descriptive message. You have two options:

  • Fix and re-upload: Correct the errors in your CSV and upload a new batch.

  • Proceed with valid rows: Confirm the batch as-is. Error rows are skipped and only valid rows are processed.

In the merchant portal, the validation results are displayed in a table with inline error indicators.

Step 3: Confirm the Batch

Via the Merchant Portal

After reviewing, click Confirm Batch. You will see a final summary showing the number of payouts to be created and the total amount. Click Confirm to proceed.

Via the API

curl https://api.antonpayments.dev/v1/batches/batch_abc123/confirm \
  -X POST \
  -H "Authorization: Bearer ak_test_..." \
  -H "Idempotency-Key: batch-confirm-2026-02-14"

Always include an Idempotency-Key when confirming to prevent accidental double-confirmation if your request is retried.

Step 4: Track Progress

After confirmation, check batch status at any time:

curl https://api.antonpayments.dev/v1/batches/batch_abc123 \
  -H "Authorization: Bearer ak_test_..."

The response includes completed_count, failed_count, and pending_count to show progress. You can also list individual payouts within the batch:

curl "https://api.antonpayments.dev/v1/batches/batch_abc123/payouts?limit=50" \
  -H "Authorization: Bearer ak_test_..."

Cancelling Before Confirmation

If you need to abort, you can cancel a batch before confirming it:

curl https://api.antonpayments.dev/v1/batches/batch_abc123/cancel \
  -X POST \
  -H "Authorization: Bearer ak_test_..."

After confirmation, the batch cannot be cancelled as a whole. Individual payouts may be cancelled if they have not yet started processing.

Did this answer your question?