Skip to main content
POST
/
api
/
v1
/
invitations
/
accept
Accept an invitation
curl --request POST \
  --url https://api.example.com/api/v1/invitations/accept \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <api-key>' \
  --data '
{
  "invitationIds": [
    "invitation-12345",
    "invitation-67890"
  ],
  "target": {
    "type": "email",
    "value": "[email protected]"
  },
  "user": {
    "name": "John Doe",
    "email": "[email protected]",
    "phone": "8675309"
  }
}
'
{
  "invitations": [
    {
      "id": "invitation-12345",
      "accountId": "account-12345",
      "attributes": {},
      "clickThroughs": 5,
      "configurationAttributes": {},
      "createdAt": "2023-10-01T12:00:00Z",
      "deactivated": false,
      "deliveryCount": 3,
      "deliveryTypes": [
        "email",
        "phone"
      ],
      "foreignCreatorId": "creator-12345",
      "invitationType": "single_use",
      "modifiedAt": "2023-10-01T12:00:00Z",
      "status": "queued",
      "target": [
        {
          "type": "email",
          "value": "[email protected]"
        }
      ],
      "views": 10,
      "widgetConfigurationId": "widget-12345",
      "deploymentId": "deployment-12345",
      "projectId": "project-67890",
      "groups": [
        {
          "type": "workspace",
          "id": "workspace-12345",
          "name": "Development Team"
        }
      ],
      "accepts": [
        {
          "id": "accept-12345",
          "status": "accepted"
        }
      ],
      "scope": "6b366c56-c0a9-4689-b763-20c890481bc8",
      "scopeType": "project",
      "expired": false,
      "source": "email",
      "expires": "2023-11-01T12:00:00Z",
      "metadata": {
        "customerId": "12345",
        "source": "web"
      },
      "passThrough": "eyJhbGciOiJBMjU2R0NNIiwiZW5jIjoiQTI1NkdDTSJ9..."
    }
  ]
}

Authorizations

x-api-key
string
header
required

Body

application/json
invitationIds
string[]
required

List of invitation IDs to accept

Example:
["invitation-12345", "invitation-67890"]
target
object

(Deprecated) The target for the invitation acceptance, such as an email address or phone number. Use the user object instead.

user
object

User information for accepting the invitation. Either email or phone must be provided. This is the preferred format.

Response

Successfully accepted the invitation

invitations
object[]
required

An array of invitations