---
updatedAt: 2026-09-18T08:56:04.000Z
agentTools:
  projectIndex: https://docs.go.v7labs.com/llms.txt
---

# Invite users to an organization workspace

Requires organization administration and a mapped active workspace in the current region. The caller's own workspace membership and role are ignored. Allows invitations to any email, including the caller's, with admin through reader roles and no group assignments. An email that the directory of the organisation manages gets no invitation: its item has `error_code` `invitation_directory_user`, and the admin adds the person to the workspace instead.

# OpenAPI definition

```json
{
  "components": {
    "schemas": {
      "Common.APIErrorDetails": {
        "description": "Additional structured error context. Shape varies by error code.\n\n- For conflict errors: contains a `conflicts` array with conflicting resources\n- For other errors: may contain arbitrary error-specific context",
        "nullable": true,
        "oneOf": [
          {
            "$ref": "#/components/schemas/Common.ConflictErrorDetails"
          },
          {
            "additionalProperties": true,
            "description": "Generic error details for non-conflict errors",
            "type": "object",
            "x-struct": null,
            "x-validate": null
          }
        ],
        "title": "Common.APIErrorDetails",
        "x-struct": "Elixir.AgiDbWeb.Schemas.Common.APIErrorDetails",
        "x-validate": null
      },
      "OrganizationInvitations.InviteUser": {
        "additionalProperties": false,
        "properties": {
          "email": {
            "$ref": "#/components/schemas/Common.Email"
          },
          "role": {
            "enum": [
              "admin",
              "editor",
              "contributor",
              "reviewer",
              "reader"
            ],
            "type": "string",
            "x-struct": null,
            "x-validate": null
          }
        },
        "required": [
          "email",
          "role"
        ],
        "title": "OrganizationInvitations.InviteUser",
        "type": "object",
        "x-struct": "Elixir.AgiDbWeb.Schemas.OrganizationInvitations.InviteUser",
        "x-validate": null
      },
      "Common.ConflictErrorDetails": {
        "additionalProperties": false,
        "description": "Details for conflict errors",
        "properties": {
          "conflicts": {
            "description": "List of conflicting resources",
            "items": {
              "additionalProperties": true,
              "type": "object",
              "x-struct": null,
              "x-validate": null
            },
            "type": "array",
            "x-struct": null,
            "x-validate": null
          }
        },
        "required": [
          "conflicts"
        ],
        "title": "Common.ConflictErrorDetails",
        "type": "object",
        "x-struct": "Elixir.AgiDbWeb.Schemas.Common.ConflictErrorDetails",
        "x-validate": null
      },
      "Common.UUID": {
        "example": "e23ff3f3-8f77-4e78-9e81-fdb25abfb781",
        "format": "uuid",
        "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$",
        "title": "Common.UUID",
        "type": "string",
        "x-struct": null,
        "x-validate": null
      },
      "OrganizationInvitations.RemovedAccess": {
        "additionalProperties": false,
        "properties": {
          "assignment_id": {
            "description": "Set when the removed entry is the `assigned` entry with this `assignment_id`.",
            "nullable": true,
            "type": "string",
            "x-struct": null,
            "x-validate": null
          },
          "email": {
            "nullable": true,
            "type": "string",
            "x-struct": null,
            "x-validate": null
          },
          "invitation_id": {
            "nullable": true,
            "type": "string",
            "x-struct": null,
            "x-validate": null
          },
          "user_id": {
            "nullable": true,
            "type": "string",
            "x-struct": null,
            "x-validate": null
          },
          "workspace_id": {
            "$ref": "#/components/schemas/Common.UUID"
          }
        },
        "required": [
          "workspace_id",
          "user_id",
          "invitation_id",
          "assignment_id",
          "email"
        ],
        "title": "OrganizationInvitations.RemovedAccess",
        "type": "object",
        "x-struct": "Elixir.AgiDbWeb.Schemas.OrganizationInvitations.RemovedAccess",
        "x-validate": null
      },
      "Invitations.InvitedUser": {
        "additionalProperties": false,
        "description": "Invited user",
        "oneOf": [
          {
            "$ref": "#/components/schemas/Invitations.InvitedUserSuccess"
          },
          {
            "$ref": "#/components/schemas/Invitations.InvitedUserError"
          }
        ],
        "title": "Invitations.InvitedUser",
        "type": "object",
        "x-struct": "Elixir.AgiDbWeb.Schemas.Invitations.InvitedUser",
        "x-validate": null
      },
      "Invitations.InvitedUserError": {
        "additionalProperties": false,
        "description": "Invited user error",
        "properties": {
          "email": {
            "$ref": "#/components/schemas/Common.Email"
          },
          "error_code": {
            "description": "Set for an error that a client can act on. `invitation_directory_user`: the\ndirectory of the workspace's organisation manages the person, so the\nperson gets a workspace assignment and not an invitation.\n",
            "enum": [
              "invitation_directory_user"
            ],
            "nullable": true,
            "type": "string",
            "x-struct": null,
            "x-validate": null
          },
          "error_message": {
            "type": "string",
            "x-struct": null,
            "x-validate": null
          },
          "role": {
            "$ref": "#/components/schemas/Invitations.Role"
          },
          "state": {
            "enum": [
              "error"
            ],
            "type": "string",
            "x-struct": null,
            "x-validate": null
          }
        },
        "required": [
          "state",
          "email",
          "role",
          "error_message"
        ],
        "title": "Invitations.InvitedUserError",
        "type": "object",
        "x-struct": "Elixir.AgiDbWeb.Schemas.Invitations.InvitedUserError",
        "x-validate": null
      },
      "OrganizationInvitations.Changes": {
        "additionalProperties": false,
        "properties": {
          "removed_access": {
            "items": {
              "$ref": "#/components/schemas/OrganizationInvitations.RemovedAccess"
            },
            "type": "array",
            "x-struct": null,
            "x-validate": null
          },
          "users": {
            "items": {
              "$ref": "#/components/schemas/OrganizationUsers.ChangedUser"
            },
            "type": "array",
            "x-struct": null,
            "x-validate": null
          }
        },
        "required": [
          "users",
          "removed_access"
        ],
        "title": "OrganizationInvitations.Changes",
        "type": "object",
        "x-struct": "Elixir.AgiDbWeb.Schemas.OrganizationInvitations.Changes",
        "x-validate": null
      },
      "Invitations.InvitedUserSuccess": {
        "additionalProperties": false,
        "description": "Invited user success",
        "properties": {
          "email": {
            "$ref": "#/components/schemas/Common.Email"
          },
          "id": {
            "$ref": "#/components/schemas/Common.UUID"
          },
          "invite_url": {
            "type": "string",
            "x-struct": null,
            "x-validate": null
          },
          "role": {
            "$ref": "#/components/schemas/Invitations.Role"
          },
          "state": {
            "enum": [
              "success"
            ],
            "type": "string",
            "x-struct": null,
            "x-validate": null
          }
        },
        "required": [
          "email",
          "role",
          "invite_url"
        ],
        "title": "Invitations.InvitedUserSuccess",
        "type": "object",
        "x-struct": "Elixir.AgiDbWeb.Schemas.Invitations.InvitedUserSuccess",
        "x-validate": null
      },
      "Common.NullableDateTime": {
        "description": "DateTime in RFC3339 format",
        "example": "2020-01-20T14:00:00Z",
        "format": "date-time",
        "nullable": true,
        "title": "Common.NullableDateTime",
        "type": "string",
        "x-struct": "Elixir.AgiDbWeb.Schemas.Common.NullableDateTime",
        "x-validate": null
      },
      "Invitations.Role": {
        "enum": [
          "admin",
          "editor",
          "contributor",
          "reviewer",
          "reader",
          "worker"
        ],
        "title": "Invitations.Role",
        "type": "string",
        "x-struct": "Elixir.AgiDbWeb.Schemas.Invitations.Role",
        "x-validate": null
      },
      "Common.Email": {
        "example": "email@example.com",
        "format": "email",
        "title": "Common.Email",
        "type": "string",
        "x-struct": "Elixir.AgiDbWeb.Schemas.Common.Email",
        "x-validate": null
      },
      "OrganizationUsers.ChangedUser": {
        "additionalProperties": false,
        "description": "A person's row in the `changes` of an endpoint that changes access. It holds the changed entries only, so it has no `origin` and no `status`: they depend on all the entries of the person. The client merges the entries into the row of the list.",
        "properties": {
          "directory": {
            "$ref": "#/components/schemas/OrganizationUsers.NullableDirectoryMarker"
          },
          "email": {
            "type": "string",
            "x-struct": null,
            "x-validate": null
          },
          "first_name": {
            "nullable": true,
            "type": "string",
            "x-struct": null,
            "x-validate": null
          },
          "id": {
            "format": "uuid",
            "nullable": true,
            "type": "string",
            "x-struct": null,
            "x-validate": null
          },
          "last_activity_at": {
            "$ref": "#/components/schemas/Common.NullableDateTime"
          },
          "last_name": {
            "nullable": true,
            "type": "string",
            "x-struct": null,
            "x-validate": null
          },
          "profile_picture_url": {
            "nullable": true,
            "type": "string",
            "x-struct": null,
            "x-validate": null
          },
          "workspace_access": {
            "description": "Empty for a person in the tail of the list: pushed by a customer's directory, with no access entry.",
            "items": {
              "$ref": "#/components/schemas/OrganizationUsers.WorkspaceAccess"
            },
            "type": "array",
            "x-struct": null,
            "x-validate": null
          }
        },
        "required": [
          "id",
          "email",
          "first_name",
          "last_name",
          "profile_picture_url",
          "last_activity_at",
          "workspace_access",
          "directory"
        ],
        "title": "OrganizationUsers.ChangedUser",
        "type": "object",
        "x-struct": "Elixir.AgiDbWeb.Schemas.OrganizationUsers.ChangedUser",
        "x-validate": null
      },
      "OrganizationUsers.Group": {
        "additionalProperties": false,
        "properties": {
          "id": {
            "$ref": "#/components/schemas/Common.UUID"
          },
          "name": {
            "type": "string",
            "x-struct": null,
            "x-validate": null
          }
        },
        "required": [
          "id",
          "name"
        ],
        "title": "OrganizationUsers.Group",
        "type": "object",
        "x-struct": "Elixir.AgiDbWeb.Schemas.OrganizationUsers.Group",
        "x-validate": null
      },
      "OrganizationInvitations.CreateResponse": {
        "additionalProperties": false,
        "description": "Create invitation response. Describes each created invitation (or an error if it failed)",
        "properties": {
          "changes": {
            "$ref": "#/components/schemas/OrganizationInvitations.Changes"
          },
          "data": {
            "items": {
              "$ref": "#/components/schemas/Invitations.InvitedUser"
            },
            "type": "array",
            "x-struct": null,
            "x-validate": null
          }
        },
        "required": [
          "data",
          "changes"
        ],
        "title": "OrganizationInvitations.CreateResponse",
        "type": "object",
        "x-struct": "Elixir.AgiDbWeb.Schemas.OrganizationInvitations.CreateResponse",
        "x-validate": null
      },
      "OrganizationInvitations.CreateRequest": {
        "additionalProperties": false,
        "properties": {
          "invitations": {
            "items": {
              "$ref": "#/components/schemas/OrganizationInvitations.InviteUser"
            },
            "minItems": 1,
            "type": "array",
            "x-struct": null,
            "x-validate": null
          }
        },
        "required": [
          "invitations"
        ],
        "title": "OrganizationInvitations.CreateRequest",
        "type": "object",
        "x-struct": "Elixir.AgiDbWeb.Schemas.OrganizationInvitations.CreateRequest",
        "x-validate": null
      },
      "OrganizationUsers.WorkspaceAccess": {
        "additionalProperties": false,
        "properties": {
          "assignment_id": {
            "description": "The pending assignment of an `assigned` or `seat_denied` entry, null for the other statuses.",
            "format": "uuid",
            "nullable": true,
            "type": "string",
            "x-struct": null,
            "x-validate": null
          },
          "groups": {
            "items": {
              "$ref": "#/components/schemas/OrganizationUsers.Group"
            },
            "type": "array",
            "x-struct": null,
            "x-validate": null
          },
          "has_group_access": {
            "type": "boolean",
            "x-struct": null,
            "x-validate": null
          },
          "invitation_id": {
            "format": "uuid",
            "nullable": true,
            "type": "string",
            "x-struct": null,
            "x-validate": null
          },
          "region": {
            "type": "string",
            "x-struct": null,
            "x-validate": null
          },
          "role": {
            "enum": [
              "owner",
              "admin",
              "editor",
              "contributor",
              "reviewer",
              "reader",
              "worker"
            ],
            "type": "string",
            "x-struct": null,
            "x-validate": null
          },
          "status": {
            "description": "`assigned`: a pending assignment of a person that a customer's directory pushed. The person gets the role at the first login. It takes no seat and sends no email. `seat_denied`: a grant of the assignment failed for lack of a seat, at the push of the directory or at the first login. It stays until a grant succeeds, for example when an admin assigns the person again after a seat becomes free, or until an admin removes it. A member entry of the same workspace hides it. `transfer_required`: an owner membership of a person whom a customer's directory deleted. The removal of the person kept the owner role of the workspace, which needs a new owner. The status ends with the owner role, or when the directory pushes the person again.",
            "enum": [
              "member",
              "invited",
              "expired",
              "assigned",
              "seat_denied",
              "transfer_required"
            ],
            "type": "string",
            "x-struct": null,
            "x-validate": null
          },
          "workspace_id": {
            "$ref": "#/components/schemas/Common.UUID"
          },
          "workspace_name": {
            "type": "string",
            "x-struct": null,
            "x-validate": null
          }
        },
        "required": [
          "has_group_access",
          "groups",
          "invitation_id",
          "assignment_id",
          "workspace_id",
          "workspace_name",
          "region",
          "status",
          "role"
        ],
        "title": "OrganizationUsers.WorkspaceAccess",
        "type": "object",
        "x-struct": "Elixir.AgiDbWeb.Schemas.OrganizationUsers.WorkspaceAccess",
        "x-validate": null
      },
      "Common.APIError": {
        "additionalProperties": false,
        "properties": {
          "code": {
            "example": "bad_request",
            "type": "string",
            "x-struct": null,
            "x-validate": null
          },
          "details": {
            "$ref": "#/components/schemas/Common.APIErrorDetails"
          },
          "message": {
            "example": "Bad Request",
            "type": "string",
            "x-struct": null,
            "x-validate": null
          }
        },
        "required": [
          "code",
          "message"
        ],
        "title": "Common.APIError",
        "type": "object",
        "x-struct": "Elixir.AgiDbWeb.Schemas.Common.APIError",
        "x-validate": null
      },
      "OrganizationUsers.NullableDirectoryMarker": {
        "additionalProperties": false,
        "description": "The SSO connection whose directory pushed the person, or null. It is set only for a connection that uses the directory user model. In the `changes` of the member and invitation endpoints it is always null: those endpoints do not look it up, so a client keeps the value that the roster gave.",
        "nullable": true,
        "properties": {
          "connection_id": {
            "$ref": "#/components/schemas/Common.UUID"
          },
          "connection_name": {
            "type": "string",
            "x-struct": null,
            "x-validate": null
          }
        },
        "required": [
          "connection_id",
          "connection_name"
        ],
        "title": "OrganizationUsers.NullableDirectoryMarker",
        "type": "object",
        "x-struct": "Elixir.AgiDbWeb.Schemas.OrganizationUsers.NullableDirectoryMarker",
        "x-validate": null
      }
    },
    "securitySchemes": {
      "ApiKeyAuth": {
        "in": "header",
        "name": "X-API-KEY",
        "type": "apiKey"
      },
      "BearerAuth": {
        "scheme": "bearer",
        "type": "http"
      }
    }
  },
  "info": {
    "title": "V7 Go API",
    "version": "0.1.0"
  },
  "openapi": "3.0.0",
  "paths": {
    "/api/organizations/{organization_id}/workspaces/{workspace_id}/invitations": {
      "post": {
        "callbacks": {},
        "description": "Requires organization administration and a mapped active workspace in the current region. The caller's own workspace membership and role are ignored. Allows invitations to any email, including the caller's, with admin through reader roles and no group assignments. An email that the directory of the organisation manages gets no invitation: its item has `error_code` `invitation_directory_user`, and the admin adds the person to the workspace instead.",
        "operationId": "organization-workspace-invitations-create",
        "parameters": [
          {
            "description": "",
            "in": "path",
            "name": "organization_id",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/Common.UUID"
            }
          },
          {
            "description": "",
            "in": "path",
            "name": "workspace_id",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/Common.UUID"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/OrganizationInvitations.CreateRequest"
              }
            }
          },
          "description": "OrganizationInvitations.CreateRequest",
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OrganizationInvitations.CreateResponse"
                }
              }
            },
            "description": "OrganizationInvitations.CreateResponse"
          },
          "400": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Common.APIError"
                }
              }
            },
            "description": "Common.APIError"
          },
          "401": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Common.APIError"
                }
              }
            },
            "description": "Common.APIError"
          },
          "403": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Common.APIError"
                }
              }
            },
            "description": "Common.APIError"
          },
          "404": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Common.APIError"
                }
              }
            },
            "description": "Common.APIError"
          },
          "409": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Common.APIError"
                }
              }
            },
            "description": "Common.APIError"
          },
          "422": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Common.APIError"
                }
              }
            },
            "description": "Common.APIError"
          },
          "500": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Common.APIError"
                }
              }
            },
            "description": "Common.APIError"
          }
        },
        "summary": "Invite users to an organization workspace",
        "tags": [
          "Organizations"
        ]
      }
    }
  },
  "security": [
    {
      "BearerAuth": []
    },
    {
      "ApiKeyAuth": []
    }
  ],
  "servers": [
    {
      "description": "EU",
      "url": "https://go.v7labs.com",
      "variables": {}
    },
    {
      "description": "US",
      "url": "https://go.us.v7labs.com",
      "variables": {}
    },
    {
      "description": "UAE",
      "url": "https://go.uae.v7labs.com",
      "variables": {}
    }
  ]
}
```