members

POST /v1/members/invitations

Invite an email to join an organization with a role.

Todos los endpoints de members

Autenticación

Envía una clave de API como token de portador. La clave debe tener el permiso members.invite; una clave que no lo tenga se rechazará con un código 403, no 404.

Donde va el ID de tu organización

Este endpoint toma org_id como un campo en el cuerpo JSON.

El id de tu organización se encuentra en la pantalla de claves de API en tu panel de control, junto a la propia clave. Es el mismo id en cada llamada que realices.

Pruébalo

Reemplaza cualquier elemento entre corchetes angulares por tus propios valores, y el marcador de posición key con una clave de tu panel de control.

curl -X POST https://api.zinndigital.com/v1/members/invitations \
  -H "Authorization: Bearer zdk_live_…" \
  -H "Content-Type: application/json" \
  -d '{ "email": <string>, "role": <string> }'

¿Has iniciado sesión? La consola de la API en tu panel de control rellena el ID de tu organización real y tu propia clave, y ejecuta la solicitud contra la API en vivo para que puedas ver la respuesta real. Abre este endpoint en la consola de la API

Detalles

Invites an **email** (the person need not exist yet — users are Keycloak subjects) to join with a role. The role is validated to be one the inviter is themselves permitted to grant: a role holding any permission the inviter lacks in that organization is refused (422), so `members.invite` is not a ladder to owner. A re-invite of the same email refreshes the pending invite. Emits `member.invited` so the invitation email is sent. Requires `members.invite` in the target org.

Cuerpo de la solicitud

NombreTipoObligatorio¿Qué es esto?
emailstring
rolestringThe role key to grant (e.g. `manager`, `billing`).
org_idstringNoOrganization to invite into; defaults to the caller's own. The caller must hold `members.invite` in **that** organization.

Respuesta

NombreTipoObligatorio¿Qué es esto?
idstring
org_idstring
org_namestringThe inviting organisation's display name, so an invitee can answer "accept?".
emailstring
rolestring
site_grantsobject[]The individual sites this invitation lends, when it was created by sharing a site with an address that had no account (`POST /v1/sites/{siteId}/collaborators`). Empty for an ord…
statusstring<pending, accepted, revoked>
expires_atstring
accepted_atstringNo
created_atstring

Errores que este endpoint puede devolver

401 · 403 · 422 · 429