members

POST /v1/members/invitations

Invite an email to join an organization with a role.

Wszystkie punkty końcowe members

Uwierzytelnianie

Wyślij klucz API jako token bearer. Klucz musi posiadać uprawnienie members.invite; klucz bez niego jest odrzucany z kodem 403, a nie 404.

Miejsce na identyfikator organizacji

Ten punkt końcowy przyjmuje org_id jako pole w treści JSON.

Identyfikator Twojej organizacji znajduje się na ekranie kluczy API w Twoim panelu, obok samego klucza. Jest to ten sam identyfikator w każdym wywołaniu, które wykonujesz.

Wypróbuj

Zastąp wszystko w nawiasach ostrych własnymi wartościami, a zastępczy znacznik klucza kluczem ze swojego pulpitu nawigacyjnego.

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> }'

Zalogowany? Konsola API w Twoim panelu uzupełnia rzeczywiste identyfikator organizacji oraz Twój własny klucz i wykonuje żądanie względem aktywnego API, dzięki czemu możesz zobaczyć rzeczywistą odpowiedź. Otwórz ten punkt końcowy w konsoli API

Szczegóły

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.

Treść żądania

NazwaTypWymaganeCo to jest
emailstringTak
rolestringTakThe role key to grant (e.g. `manager`, `billing`).
org_idstringNieOrganization to invite into; defaults to the caller's own. The caller must hold `members.invite` in **that** organization.

Odpowiedź

NazwaTypWymaganeCo to jest
idstringTak
org_idstringTak
org_namestringTakThe inviting organisation's display name, so an invitee can answer "accept?".
emailstringTak
rolestringTak
site_grantsobject[]TakThe 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>Tak
expires_atstringTak
accepted_atstringNie
created_atstringTak

Błędy, które ten punkt końcowy może zwrócić

401 · 403 · 422 · 429