Invitations - Admin

Bulk create invitations

Create up to 20 invitations at once.

Required body:

  • invitations: list of {email, fullname (optional), idpointofsale, idrole (optional — see below)}

Optional body:

  • idrole: a default applied to every item that omits its own.

Every row must end up with a role, exactly like POST /invitations. The role may arrive per item or as the batch-level default, but a row that resolves to neither is refused.

This used to be optional, on the argument that none of the endpoint's callers offered a role field so nobody could be deceived about which one took effect, and that the first-run onboarding wizard had no roles to choose from anyway. Both halves are gone: the wizard now has a role picker (companies get their template copies at creation, so the list is never empty), and the Completo fallback the argument leaned on has been removed — a roleless invitation today grants NOTHING, which is a worse silent outcome than the one the optionality was defending.

Refusal is PER ROW rather than a 400 for the batch: this endpoint's contract is best-effort, and a stale tab posting twenty roleless rows should surface twenty readable errors, not discard nineteen valid invitations.

Returns per-item results with success/error status. Continues on individual failures (best-effort).

post/api/invitations/bulk

Headers

x-api-tokenstring nullable

Request body

object required

Response

Successful Response

object required

Changes

No recorded changes to this endpoint across all 1 revision of this API.