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

# Create invitation

> Create an invitation.

`veryfront__create_project_invitation`

Requires project.invites.manage.

## Access

No external-service connection is required. Use a Veryfront credential with access to the requested resources.

**Call type:** Can change resources.

## Arguments

| Field | Type | Required | Description and constraints |
| - | - | - | - |
| `project_reference` | `string` | No | Project ID or slug. |
| `email` | `string` | Yes | Email address to invite; stored in lowercase. Maximum length: `100`. Format: `email`. |
| `role` | `string` | Yes | Role to grant: admin, editor or viewer. Values: `"admin"`, `"editor"`, `"viewer"`. |

## Example request

Send this JSON-RPC request through an initialized MCP client. Replace sample identifiers and values before calling the tool. See [MCP client setup](https://veryfront.com/docs/cloud/getting-started/connect-mcp.md).

```json title="request.json" theme={null}
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "veryfront__create_project_invitation",
    "arguments": {
      "email": "user@example.com",
      "role": "admin"
    }
  }
}
```

## Result

The published output shape is summarized below. Inspect both the MCP response content and `isError` when handling a call.

| Field | Type | Required | Description and constraints |
| - | - | - | - |
| `outcome` | `string` | Yes | `member_added` when the email already belongs to a user, who is added to the project (or has their role changed); `invitation_created` when a pending invitation was stored. Values: `"member_added"`, `"invitation_created"`. |
| `invitation` | `object or null` | Yes | The pending invitation; null when outcome is `member_added`. |
| `user_id` | `string or null` | Yes | The added user; set only when outcome is `member_added`. |
| `email_sent` | `boolean` | Yes | Whether the email service accepted the notification send. False when sending is unavailable or fails; it does not confirm inbox delivery. |

## Full schemas

```json title="input-schema.json" theme={null}
{
  "type": "object",
  "properties": {
    "project_reference": {
      "type": "string",
      "description": "Project ID or slug."
    },
    "email": {
      "type": "string",
      "format": "email",
      "maxLength": 100,
      "description": "Email address to invite; stored in lowercase."
    },
    "role": {
      "type": "string",
      "enum": [
        "admin",
        "editor",
        "viewer"
      ],
      "description": "Role to grant: admin, editor or viewer."
    }
  },
  "required": [
    "email",
    "role"
  ],
  "additionalProperties": false,
  "description": "Arguments for the create_project_invitation tool.",
  "$schema": "http://json-schema.org/draft-07/schema#"
}
```

```json title="output-schema.json" theme={null}
{
  "type": "object",
  "properties": {
    "outcome": {
      "type": "string",
      "enum": [
        "member_added",
        "invitation_created"
      ],
      "description": "member_added when the email already belongs to a user, who is added to the project (or has their role changed); invitation_created when a pending invitation was stored."
    },
    "invitation": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "id": {
              "type": "string",
              "description": "Invitation ID."
            },
            "project_id": {
              "type": "string",
              "format": "uuid",
              "description": "ID of the project the invitation is for."
            },
            "email": {
              "type": "string",
              "description": "Email address the invitation was sent to."
            },
            "role": {
              "type": "string",
              "enum": [
                "admin",
                "editor",
                "viewer"
              ],
              "description": "Role the invitation grants: admin, editor or viewer."
            },
            "created_at": {
              "type": [
                "string",
                "null"
              ],
              "description": "When the invitation was created (RFC 3339), or null if not recorded."
            }
          },
          "required": [
            "id",
            "project_id",
            "email",
            "role",
            "created_at"
          ],
          "additionalProperties": false,
          "description": "Structured invitation details associated with this tool result."
        },
        {
          "type": "null",
          "description": "The invitation returned by the tool."
        }
      ],
      "description": "The pending invitation; null when outcome is member_added."
    },
    "user_id": {
      "anyOf": [
        {
          "type": "string",
          "format": "uuid"
        },
        {
          "type": "null",
          "description": "The user id returned by the tool."
        }
      ],
      "description": "The added user; set only when outcome is member_added."
    },
    "email_sent": {
      "type": "boolean",
      "description": "Whether the email service accepted the notification send. False when sending is unavailable or fails; it does not confirm inbox delivery."
    }
  },
  "required": [
    "outcome",
    "invitation",
    "user_id",
    "email_sent"
  ],
  "additionalProperties": false,
  "description": "Structured result returned by the create_project_invitation tool.",
  "$schema": "http://json-schema.org/draft-07/schema#"
}
```

<details>
  <summary>Try this tool</summary>

  Replace sample arguments with values for your project or connected account. Calls run only when you select Run tool.

  MCP tool call

  Call `veryfront__create_project_invitation` against the Veryfront MCP endpoint.

  Bearer token or API key

  Arguments (JSON)

  Run this tool with these arguments.

  Run tool

  Output JSON

  <pre />
</details>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.