Skip to content

Invite a user
Stable

Request

Invite a user to a tenant

Security
apiKey
Path
enterprise_idstring, (uuid)required

Enterprise ID

Bodyapplication/jsonrequired
emailstring, (email)(email)required
metaobject(meta data of user)required
connection_idstring(connection id)
cURL
curl -i -X POST \
  'https://develop-api.esper.io/_mock/openapi/authn2/v0/tenant/{enterprise_id}/invite' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "email": "user@example.com",
    "meta": {
      "email": "user@example.com",
      "profile": {
        "role": "Enterprise Admin",
        "enterprise": "796caaf9-a7de-4817-9ffa-39d04bf83de9",
        "groups": [
          "497f6eca-6276-4993-bfeb-53cbbbba6f08"
        ],
        "authz_role_id": "c85d5e04-56ba-49f9-8ef1-94165471fa4c"
      }
    },
    "connection_id": "string"
  }'

Responses

Invite sent to user

Bodyapplication/json
idstring(id)
emailstring, (email)(email)
tenant_idstring(id of the tenant)
idp_invite_idstring(id of the idp invitation)
metaobject(meta data of user)
connection_idstring(connection id)
send_invitation_emailboolean(send invitation email)
invitation_urlstring(invitation URL)
created_atstring, (date-time)(created at)
updated_atstring, (date-time)(updated at)
Response
{ "id": "string", "email": "user@example.com", "tenant_id": "string", "idp_invite_id": "string", "meta": {}, "connection_id": "string", "send_invitation_email": true, "invitation_url": "string", "created_at": "2019-08-24T14:15:22Z", "updated_at": "2019-08-24T14:15:22Z" }