Chelabase
ManagementMembers

Invite a person

POST
/v1/invites

Matches the email to a person: an existing member just gets the grants, all or none (200); anyone else is invited until they accept (201), a removed member and a person with an account included. By email, an account with a password and a verified email gets a notice to sign in and accept, with a link to Studio's /accept-invite and no code; anyone else (a new person, whose account is made now, or one whose account has no password or an unverified email) gets an invite code. A person whose own sign-up is pending is 409 signup_pending: approve it instead. With delivery: "link" (only for a new person, or an account with no password and an unverified email that no other tenant holds by an invite or a membership; else 409 link_not_allowed, send by email) nothing is mailed (no SMTP needed): the response carries the link with its code as invite_url, once, with Cache-Control: no-store; it is never stored or logged. Invite mails and codes are limited to 5 per person per hour, resends included (429 rate_limited). Every grant is checked first, as putProjectGrant checks it, with the member's overrides.

Authorization

bearer
AuthorizationBearer <token>

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

delivery?Delivery

How the invitee gets the link. Default email.

Value in

  • "email"
  • "link"
email*string

Trimmed and lowercased.

grants?array<>

One grant per project at most; none is fine (the person starts with no access).

team_ids?array<>

Teams of the tenant the person joins (at most 50 after duplicates are dropped; each must be a team of the tenant, else 422 naming it in team_id); empty is none. The grants and the teams are checked together on the person's union, per project.

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/v1/invites" \  -H "Content-Type: application/json" \  -d '{    "email": "string"  }'
{  "invite_url": "string",  "member": {    "accepted_at": "2019-08-24T14:15:22Z",    "access": {      "level": "tenant_admin",      "projects": [        {          "platform_role": "viewer",          "project_id": "405d8375-3514-403b-8c43-83ae74cfe0e9",          "via": "own"        }      ]    },    "created_at": "2019-08-24T14:15:22Z",    "display_name": "string",    "email": "string",    "has_access": true,    "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",    "invite": {      "expires_at": "2019-08-24T14:15:22Z",      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08"    },    "status": "invited",    "suspended_at": "2019-08-24T14:15:22Z",    "suspended_by": "c2e368d8-db1b-4e27-8850-4fa018b3a2bc",    "tenant_admin": true  },  "outcome": "invited"}