members
POST /v1/members/invitations
Invite an email to join an organization with a role.
प्रमाणीकरण
बेरर टोकन म्हणून API की पाठवा. की मध्ये members.invite परवानगी असणे आवश्यक आहे; ती नसलेली की 404 ऐवजी 403 सह नाकारली जाते.
जिथे तुमचा ऑर्गनायझेशन आयडी (organization id) जाईल
हा एंडपॉइंट JSON बॉडीमधील फील्ड म्हणून org_id घेतो.
तुमची संस्था आयडी (organisation id) तुमच्या डॅशबोर्डवरील API की स्क्रीनवर, की च्या बाजूला आहे. तुम्ही केलेल्या प्रत्येक कॉलमधील तोच आयडी असतो.
प्रयत्न करा
कोनसांस्कृतिक कंसात (<>) असलेली कोणतीही गोष्ट तुमच्या स्वतःच्या मूल्यांनी बदला आणि key प्लेसहोल्डरला तुमच्या डॅशबोर्डवरील किने बदला.
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> }'साइन इन केलेले आहे? तुमच्या डॅशबोर्डमधील API कन्सोल तुमची खरी संस्था आयडी आणि तुमची स्वतःची की आपोआप भरतो आणि लाइव्ह API विरुद्ध विनंती कार्यान्वित करतो जेणेकरून तुम्हाला वास्तविक प्रतिसाद पाहता येईल. एपी कन्सोलमध्ये हा एंडपॉइंट उघडा
तपशील
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.
विनंती मुख्य भाग
| नाव | प्रकार | आवश्यक | हे काय आहे |
|---|---|---|---|
email | string | होय | — |
role | string | होय | The role key to grant (e.g. `manager`, `billing`). |
org_id | string | नाही | Organization to invite into; defaults to the caller's own. The caller must hold `members.invite` in **that** organization. |
प्रतिसाद
| नाव | प्रकार | आवश्यक | हे काय आहे |
|---|---|---|---|
id | string | होय | — |
org_id | string | होय | — |
org_name | string | होय | The inviting organisation's display name, so an invitee can answer "accept?". |
email | string | होय | — |
role | string | होय | — |
site_grants | object[] | होय | 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… |
status | string<pending, accepted, revoked> | होय | — |
expires_at | string | होय | — |
accepted_at | string | नाही | — |
created_at | string | होय | — |
ही एंडपॉइंट परत करू शकेल अशा त्रुटी
401 · 403 · 422 · 429