Skip to content
myela

Creates each customer through the same validation, tenant boundary, and provider mirror as the single-customer route. The idempotency key identifies the whole frozen job.

Bulk create customers

POST/v1/bulk_jobs/customersLink

Creates each customer through the same validation, tenant boundary, and provider mirror as the single-customer route. The idempotency key identifies the whole frozen job.

SandboxSecret keybulkJobs.createCustomers

Request fields

Edit a field and the generated request updates immediately.

Request body
Optional fields1
arrayoptional

The lines being billed. Each carries a description, a quantity, and a unitAmount in minor units; the invoice totals itself from them, so amount becomes optional.

Response contract

The successful wire shape and errors an integration should branch on.

200

Bulk job

application/json
idstringrequired
Unique bulk job identifier.
object"bulk_job"required
Stable resource discriminator.
typestringrequired
Which single-item operation every row runs: customers.create, payments.capture or invoices.schedule (create, then schedule).
statusstringrequired
pending, processing, completed, completed_with_errors or failed.
totalItemsintegerrequired
Rows submitted.
processedItemsintegerrequired
Rows that reached a final state.
succeededItemsintegerrequired
Rows whose operation succeeded.
failedItemsintegerrequired
Rows refused definitively.
unresolvedItemsintegerrequired
Rows to resume: a capture whose money outcome must be reconciled first, or an invoice row stopped by a temporary problem.
expiresAtstringrequired
When the job can no longer be resumed.
createdAtstringrequired
When the job was created.
itemsarrayrequired
One entry per row: its number, status, the created or captured resource on success, or a code and message on failure. A refused invoice row adds error.detailCode, the code single create returns in details.code, and still names its invoice in result if one was created.
warningobject
Only when an invoices job is created on an environment with no automatic collection: code INVOICE_SCHEDULER_DISABLED and a message. The invoices are scheduled, but nothing will charge them on its own.
Example response
{
  "id": "bj_01JEXAMPLE",
  "object": "bulk_job",
  "type": "payments.capture",
  "status": "completed_with_errors",
  "totalItems": 3,
  "processedItems": 3,
  "succeededItems": 2,
  "failedItems": 0,
  "unresolvedItems": 1,
  "expiresAt": "2026-09-05T00:00:00.000Z",
  "createdAt": "2026-09-04T00:00:00.000Z",
  "items": [
    {
      "row": 1,
      "status": "succeeded",
      "result": {
        "id": "pay_01JEXAMPLE",
        "status": "pending_settlement"
      }
    }
  ],
  "warning": {
    "code": "INVOICE_SCHEDULER_DISABLED",
    "message": "Automatic collection is not running on this environment."
  }
}
Error responses
401authentication_failed

The key is missing, malformed, revoked, or invalid for this environment.

403permission_denied

The key does not have bulkJobs.createCustomers.

422invalid_request

One or more request fields are invalid.