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

# Invite user to workspace

> Invites a user to the workspace with a role. Unofficial API — also requires `X-Notion-Space-ID` and `X-Notion-User-ID`. Requires a **Basic** license.



## OpenAPI

````yaml /api-reference/notion/openapi.json post /api/v1/notion/workspace-invite
openapi: 3.1.0
info:
  title: Magic Meal Kits — Notion API
  version: 1.0.0
  description: >-
    Bulk Notion operations, database queries, markdown, publishing,
    workspace/team management, file uploads, and transcription through your
    Magic Meal Kits server. Backs the **Notion Plus (Magic Meal Kits)** Make.com
    app.


    Auth needs two things: the MMK `X-API-KEY` (your deployment) **and** your
    Notion credentials in `X-Notion-*` headers (the caller supplies these — they
    are not stored server-side). Most endpoints are **Basic**; a handful of
    advanced ones are **Pro** (a Basic key on a Pro route gets `400` `you are
    not a magic meal kits PRO user`).
  license:
    name: Proprietary
    identifier: LicenseRef-Proprietary
servers:
  - url: https://{deployment}
    description: Your Magic Meal Kits deployment
    variables:
      deployment:
        default: magic-meal-kits-xxxxx.run.app
        description: Your Cloud Run host (without protocol)
security:
  - ApiKeyAuth: []
    NotionToken: []
tags:
  - name: Bulk operations
    description: Insert, update, upsert, delete, and check records in batches.
  - name: Database & schema
    description: Fetch database/data-source schemas and property options.
  - name: Pages & content
    description: Markdown append/replace and page creation.
  - name: Data sources (v2)
    description: >-
      Official Notion API 2025-09-03 — multi-data-source query, templates,
      pages.
  - name: Publishing
    description: Publish/unpublish pages and set block configuration.
  - name: Workspace & teams
    description: Teams, invites, and workspace membership.
  - name: Files
    description: Upload files to Notion and export pages.
  - name: Transcription
    description: Read audio-block transcriptions from a page.
  - name: AI, comments & users
    description: AI summaries, comments, and user listing (Pro).
paths:
  /api/v1/notion/workspace-invite:
    post:
      tags:
        - Workspace & teams
      summary: Invite user to workspace
      description: >-
        Invites a user to the workspace with a role. Unofficial API — also
        requires `X-Notion-Space-ID` and `X-Notion-User-ID`. Requires a
        **Basic** license.
      operationId: notionWorkspaceInvite
      parameters:
        - $ref: '#/components/parameters/NotionSpaceId'
        - $ref: '#/components/parameters/NotionUserId'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              additionalProperties: true
            example:
              email: a@b.com
              role: editor
      responses:
        '200':
          description: Result
          content:
            application/json:
              schema:
                type: object
                additionalProperties: true
        '400':
          $ref: '#/components/responses/BadRequest'
components:
  parameters:
    NotionSpaceId:
      name: X-Notion-Space-ID
      in: header
      required: false
      schema:
        type: string
      description: Notion workspace (space) ID — required for unofficial-API operations.
    NotionUserId:
      name: X-Notion-User-ID
      in: header
      required: false
      schema:
        type: string
      description: Notion user ID — required for unofficial-API operations.
  responses:
    BadRequest:
      description: >-
        Invalid request, missing header (e.g. `X-Notion-Token`), or a Pro-only
        route called with a Basic key (`you are not a magic meal kits PRO
        user`).
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
  schemas:
    ErrorResponse:
      type: object
      properties:
        success:
          type: boolean
          example: false
        error:
          type: string
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-API-KEY
      description: Your deployment's API key (MMK_API_KEY).
    NotionToken:
      type: apiKey
      in: header
      name: X-Notion-Token
      description: >-
        Your Notion integration token / internal token. Supplied by the caller
        (not stored server-side).

````