---
title: "Create a payment batch · Payment Batches · Practice Manager API · COUNT Partner API"
description: "Creates an empty draft batch. POST /firm-partners/workspace/payment-batches"
canonical: "https://developers.getcount.com/practice-manager/reference/payment-batches/create-payment-batch"
source: "https://developers.getcount.com/practice-manager/reference/payment-batches/create-payment-batch"
---
[Payment Batches](https://developers.getcount.com/practice-manager/reference/payment-batches) / Create a payment batch

# Create a payment batch

POST NZ· GST `/firm-partners/workspace/payment-batches`

Creates an empty draft batch.

HMAC signature only

[Supplier Bank Accounts API](https://developers.getcount.com/practice-manager/reference/vendor-bank-accounts) [Bills API](https://developers.getcount.com/practice-manager/reference/bills)

#### Headers

`count-workspace-id` uuid required

UUID of the client workspace to act on. It must be one of your firm's client workspaces (or the firm's own workspace) and within the API key's client workspaces.

#### Request body

`fromAccountUuid` uuid required

The bank account paying, from the Chart of Accounts.

`paymentDate` date required

When the bank should pay, YYYY-MM-DD.

`bank` enum

The bank file format. Taken from the paying account when omitted.

One of: `asb`, `bnz`, `anz`, `kiwibank`, `westpac`, `generic`

`statementDetails` string

What appears on your own statement.

`fromAccountNumber` string

Your own account number. Taken from the paying account when omitted; the BNZ, Kiwibank and Westpac formats need it.

#### Responses

`201` The batch.

`400` Not a New Zealand workspace, an invalid date, or a bank format that needs your account number and has none.

`401` Missing signing headers, an invalid HMAC signature, or a timestamp more than 5 minutes off. [Troubleshoot](https://developers.getcount.com/practice-manager/authentication#errors)

`403` The key is inactive or its scope does not allow this request, the workspace is not managed by your firm or is outside the key's client workspaces, the workspace has no active subscription, or it is portal-only and the route needs bookkeeping. [Troubleshoot](https://developers.getcount.com/practice-manager/authentication#errors)

`404` Paying account not found.

`429` Rate limit exceeded (100 requests per minute per firm user of each app, or 10,000 per minute per app). [Troubleshoot](https://developers.getcount.com/practice-manager/authentication#errors)

[Previous GET Get a payment batch](https://developers.getcount.com/practice-manager/reference/payment-batches/get-payment-batch) [Next POST Add bills to a payment batch](https://developers.getcount.com/practice-manager/reference/payment-batches/add-bills-to-payment-batch)

POST `https://api.getcount.com/firm-partners/workspace/payment-batches`

Request

```javascript
import crypto from 'node:crypto';

const BASE_URL = 'https://api.getcount.com';
const CLIENT_ID = process.env.COUNT_CLIENT_ID;
const CLIENT_SECRET = process.env.COUNT_CLIENT_SECRET;

const method = 'POST';
const signingPath = '/workspace/payment-batches';
const timestamp = Math.floor(Date.now() / 1000).toString();
const body = {
  "fromAccountUuid": "0190a1b2-c3d4-7e5f-8a9b-0c1d2e3f4a10",
  "paymentDate": "2026-11-20"
};
const bodyString = JSON.stringify(body);

const bodyHash = crypto.createHash('sha256').update(bodyString).digest('hex');
const baseString = `${method}:${signingPath}:${timestamp}:${bodyHash}`;
const signature = crypto.createHmac('sha256', CLIENT_SECRET).update(baseString).digest('hex');

const response = await fetch(`${BASE_URL}/firm-partners/workspace/payment-batches`, {
  method,
  headers: {
    'x-client-id': CLIENT_ID,
    'x-timestamp': timestamp,
    'x-signature': signature,
    'Content-Type': 'application/json',
    'count-workspace-id': '5e4d3c2b-1a09-4f8e-8d7c-6b5a49382716',
  },
  body: bodyString,
});

console.log(await response.json());
```

Response · 201

```json
{
  "status": "success",
  "message": "Payment batch created",
  "data": {
    "paymentBatch": {
      "id": "0193a1c2-7b4d-7e10-9a2f-5c6d7e8f9b01",
      "reference": "BATCH-261120-01",
      "status": "draft",
      "paymentDate": "2026-11-20",
      "fromAccount": {
        "id": "0190a1b2-c3d4-7e5f-8a9b-0c1d2e3f4a10",
        "name": "ASB Business"
      },
      "fromAccountNumber": "12-3456-7890123-00",
      "bank": "asb",
      "bankCountry": "NZ",
      "statementDetails": "Supplier run",
      "total": "1250.0000",
      "createdBy": {
        "id": "0190a1b2-c3d4-7e5f-8a9b-0c1d2e3f4a03",
        "firstName": "Ana",
        "lastName": "Reyes",
        "email": "ana@example.com"
      },
      "downloadedAt": null,
      "sentAt": null,
      "paidAt": null,
      "reconciledAt": null,
      "createdAt": "2026-01-15T10:30:00.000Z",
      "updatedAt": "2026-01-28T14:22:30.000Z",
      "lines": [
        {
          "id": "0193a1c2-7b4d-7e10-9a2f-5c6d7e8f9b02",
          "bill": {
            "id": "0190a1b2-c3d4-7e5f-8a9b-0c1d2e3f4a01",
            "billNumber": "INV-0042"
          },
          "vendor": {
            "id": "d4e5f6a7-b8c9-0123-defa-234567890123",
            "name": "Harbourside Office Supplies Ltd"
          },
          "payeeBankAccount": {
            "nzBankAccount": "12-3456-7890123-001",
            "accountName": "Harbourside Office Supplies"
          },
          "particulars": "Acme Ltd",
          "code": "INV-0042",
          "reference": "ACME-001",
          "dueAmount": "1250.0000",
          "paymentAmount": "1250.0000",
          "reconciledAt": null
        }
      ],
      "approvers": [
        {
          "user": {
            "id": "0190a1b2-c3d4-7e5f-8a9b-0c1d2e3f4a02",
            "firstName": "Ben",
            "lastName": "Ito",
            "email": "ben@example.com"
          },
          "status": "pending",
          "assignedAt": "2026-01-28T14:22:30.000Z",
          "approvedAt": null,
          "rejectedAt": null,
          "rejectionReason": null
        }
      ]
    }
  }
}
```
