Skip to main content
POST
/
v1
/
orgs
/
{orgId}
/
invitations
Create organization invitation
curl --request POST \
  --url https://api.openworklabs.com/v1/orgs/{orgId}/invitations \
  --header 'Content-Type: application/json' \
  --data '
{
  "email": "jsmith@example.com",
  "role": "<string>"
}
'
{
  "invitationId": "<string>",
  "email": "jsmith@example.com",
  "role": "<string>",
  "expiresAt": "2023-11-07T05:31:56Z"
}

Path Parameters

orgId
string<typeid>
required

Den TypeID with 'org_' prefix and a 26-character base32 suffix.

Required string length: 30
Pattern: ^org_.*

Body

application/json
email
string<email>
required
Pattern: ^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$
role
string
required
Required string length: 1 - 64

Response

Existing invitation refreshed successfully.

invitationId
string<typeid>
required

Den TypeID with 'inv_' prefix and a 26-character base32 suffix.

Required string length: 30
Pattern: ^inv_.*
email
string<email>
required
Pattern: ^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$
role
string
required
expiresAt
string<date-time>
required
Pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$