> ## Documentation Index
> Fetch the complete documentation index at: https://docs.caret.so/llms.txt
> Use this file to discover all available pages before exploring further.

# Create Invite

> Create a new invite for the workspace

### Body

<ParamField body="email" type="string" required>
  Email address of the person to invite.
</ParamField>

<ParamField body="role" type="string" default="member">
  Role to assign to the invitee. One of `admin`, `member`.
</ParamField>

<ParamField body="isUrlInvite" type="boolean" default="false">
  Whether to create a URL-based invite (`true`) or send an email invitation
  (`false`).
</ParamField>

### Response

<ResponseField name="invite" type="object">
  <Expandable title="Invite">
    <ResponseField name="id" type="string">
      Unique identifier for the invite.
    </ResponseField>

    <ResponseField name="email" type="string">
      Email address of the invitee.
    </ResponseField>

    <ResponseField name="code" type="string">
      Invite code.
    </ResponseField>

    <ResponseField name="role" type="string">
      Role assigned to the invitee.
    </ResponseField>

    <ResponseField name="expiresAt" type="string">
      ISO8601 timestamp when the invite expires.
    </ResponseField>

    <ResponseField name="createdAt" type="string">
      ISO8601 timestamp when the invite was created.
    </ResponseField>

    <ResponseField name="isUrlInvite" type="boolean">
      Whether this is a URL-based invite.
    </ResponseField>
  </Expandable>
</ResponseField>

<RequestExample>
  ```bash theme={null}
  curl --request POST \
    --url https://api.caret.so/v1/invites \
    --header 'Authorization: Bearer <token>' \
    --header 'Content-Type: application/json' \
    --data '{
    "email": "user@example.com",
    "role": "member",
    "isUrlInvite": false
  }'
  ```
</RequestExample>

<ResponseExample>
  ```json theme={null}
  {
    "invite": {
      "id": "inv_123",
      "email": "user@example.com",
      "code": "abc123xy",
      "role": "member",
      "expiresAt": "2026-02-27T10:00:00Z",
      "createdAt": "2026-01-28T10:00:00Z",
      "isUrlInvite": false
    }
  }
  ```
</ResponseExample>
