---
title: "Batch create program members"
method: POST
path: "/v2/loyalties/programs/{programId}/members/batch"
tags: ["Programs"]
---

# Batch create program members

`POST /v2/loyalties/programs/{programId}/members/batch`

<Warning>

<Badge color="yellow">BETA endpoint</Badge>

This is a work-in-progress documentation of a BETA endpoint. The parameters, fields, request and response bodies, and other data may subject to change. If you want to share feedback or improvements, contact [Voucherify support](https://www.voucherify.io/contact-support) or your Technical Account Manager.

</Warning>

Schedules asynchronous batch creation of program members. The request body is a
JSON array of member entries (maximum body size 10485760 bytes / 10 MB). The
request is processed asynchronously in batches of 100 entries.

The program must exist (404) and be in `ACTIVE` status (423). Each entry is
validated during background processing the same way as single member creation;
entries that fail validation (missing/invalid `customer_id`, unknown customer,
invalid `status`, member already exists) are reported per-entry in the async action
result and do not fail the whole batch (conflicting members are skipped).

Returns 202 with the identifier of the scheduled async action.

## Path parameters

- `programId` string, required

## Request body

- MemberBatchCreateItem[] — Request body for batch member creation - a JSON array of member entries. The raw body is limited to 10485760 bytes (10 MB) and is processed asynchronously in batches of 100 entries. Each entry is validated like a single member creation request during background processing; per-entry failures (invalid customer_id format, unknown customer, invalid status, member already exists) are reported in the async action result.
  - `customer_id` string, required — ID of an existing customer to enroll as a member. Required per entry.
  - `status` 'ACTIVE' | 'INACTIVE', nullable — Initial member status. Defaults to `ACTIVE` when omitted.
  - `metadata` object, nullable — Free-form metadata attached to the member. Defaults to an empty object.

## Response `202`

Batch creation has been scheduled.

- MemberBatchScheduleResponse — Result of scheduling the members batch creation.
  - `async_action_id` string, required — ID of the scheduled async action processing the batch.

## Other responses

- `400` — Validation error - request body or query parameters failed validation, or the operation is not allowed in the current resource state.
- `404` — Resource not found.
- `409` — Conflict - e.g. duplicate resource or invalid state transition.
- `423` — Resource locked - a related resource is in a state that prevents this operation.
- `500` — Internal server error.

---

[API](https://skmtc.net/voucherifyio/apis/voucherify-loyalty-v2-api.md) · [All operations](https://skmtc.net/voucherifyio/apis/voucherify-loyalty-v2-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/voucherifyio/voucherify-loyalty-v2-api/versions/f6f2f3388362/schema)
