---
title: "Sync a batch of customers"
method: POST
path: "/sync/businesses/{business_id}/customers/batch"
tags: ["Sync"]
---

# Sync a batch of customers

`POST /sync/businesses/{business_id}/customers/batch`

## Request

- Base URL: `https://api.pocketflows.com`
- URL: `https://api.pocketflows.com/sync/businesses/{business_id}/customers/batch`
- Auth: HTTP basic
- TypeScript: <https://skmtc.dev/pocketflows/apis/pocketflows-api/docs/sync/businesses/:business_id/customers/batch/post.ts> (a function with typed inputs; its response is checked against the schema)

## Path parameters

- `business_id` string, required

## Request body

- object
  - `customers` union[], required: The customers to sync
    - union
      - object
        - `id` string, required: The ID of the customer
        - `external_id` string, nullable: The external ID of the customer
        - `phone_number` string, nullable: The phone number of the customer
        - `email_address` string, nullable: The email address of the customer
        - `metadata` object: The metadata of the customer
        - `full_name` string, nullable: The full name of the customer
        - `first_name` string, nullable: The first name of the customer
        - `last_name` string, nullable: The last name of the customer
      - object
        - `external_id` string, required: The external ID of the customer
        - `phone_number` string, nullable: The phone number of the customer
        - `email_address` string, nullable: The email address of the customer
        - `metadata` object: The metadata of the customer
        - `full_name` string, nullable: The full name of the customer
        - `first_name` string, nullable: The first name of the customer
        - `last_name` string, nullable: The last name of the customer

## Response `200`

The customers that were synced

- object
  - `customers` Customer[], required: The customers that were synced. Will be `null` for customers that had errors
    - `id` string, required: The ID of the customer
    - `external_id` string, nullable, required: The external ID of the customer
    - `email_address` string, nullable, required: The email address of the customer
    - `phone_number` string, nullable, required: The phone number of the customer
    - `full_name` string, nullable, required: The full name of the customer
    - `first_name` string, nullable, required: The first name of the customer
    - `last_name` string, nullable, required: The last name of the customer
    - `metadata` object, required: The metadata associated with this customer
    - `unsubscribed` 'future' | 'campaign', nullable, required: The unsubscribe status of the customer
  - `errors` unknown[], required: The errors that occurred during the sync
    - unknown

## Changes

- **2026-10-07** `a8a7fb59cefc`: 1 breaking, 3 info
  - removed `subschema #1, subschema #2` from the `customers/items/` request property `anyOf` list
  - added `subschema #1, subschema #2` to the `customers/items/` request property `anyOf` list
  - added the required property `customers/items/first_name` to the response with the `200` status
  - added the required property `customers/items/last_name` to the response with the `200` status

[Operation history](https://skmtc.dev/pocketflows/apis/pocketflows-api/changes/sync/businesses/:business_id/customers/batch/post.md)

---

[API](https://skmtc.dev/pocketflows/apis/pocketflows-api.md) - [All operations](https://skmtc.dev/pocketflows/apis/pocketflows-api/llms.txt) - [OpenAPI document](https://skmtc.dev/pocketflows/apis/pocketflows-api/revisions/3b2a2fc1c31a?raw)
