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

# Block emails

> Block one or more emails with an optional note. Emails that are already blocked are left as they are, note included. The response lists each distinct email once, sorted by address, whether newly blocked or already blocked.

> [!NOTE]
>
> Replace `{your-subdomain}` with your workspace’s subdomain. \
> Learn how to find your subdomain in [Workspace subdomain](https://apidocs.neetocal.com/api/workspace-subdomain.md).


## OpenAPI

````yaml bundled/blocked-emails.yaml POST /blocked-emails
openapi: 3.0.3
info:
  title: NeetoCal Blocked Emails APIs
  version: 2.0.0
servers:
  - description: NeetoCal APIs
    url: https://{your-subdomain}.neetocal.com/api/external/v2
    variables:
      your-subdomain:
        default: spinkart
        description: >-
          Replace **spinkart** with your [workspace's
          subdomain](/api/workspace-subdomain).
security: []
tags:
  - name: Blocked emails
    description: >-
      APIs to manage blocked emails. A blocked email cannot book a meeting or
      buy a package. Emails are stored lowercased and without `+tags`. Gmail
      addresses are also stored without dots, so `John.Doe+promo@gmail.com` is
      stored as `johndoe@gmail.com`.
paths:
  /blocked-emails:
    post:
      tags:
        - Blocked emails
      summary: Block emails
      description: >-
        Block one or more emails with an optional note. Emails that are already
        blocked are left as they are, note included. The response lists each
        distinct email once, sorted by address, whether newly blocked or already
        blocked.
      parameters:
        - $ref: '#/components/parameters/api_key_header'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/blocked_email_create_request'
            example:
              blocked_email:
                emails:
                  - spammer@example.com
                  - no.show@gmail.com
                note: Repeated spam bookings
      responses:
        '201':
          description: Created - Emails blocked successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/blocked_email_create_response'
        '422':
          description: >-
            Unprocessable Entity - `emails` is missing or empty, an email is
            invalid, or `note` is longer than 255 characters. If any email is
            invalid, none are blocked.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
              example:
                error: Email is invalid
components:
  parameters:
    api_key_header:
      in: header
      name: X-Api-Key
      description: >-
        Use the X-Api-Key header to provide your workspace API key. Refer to
        [Authentication](/api/authentication) for more information.
      required: true
      schema:
        type: string
  schemas:
    blocked_email_create_request:
      type: object
      required:
        - blocked_email
      properties:
        blocked_email:
          type: object
          properties:
            emails:
              type: array
              minItems: 1
              items:
                type: string
              description: Emails to block.
              example:
                - spammer@example.com
                - no.show@gmail.com
            note:
              type: string
              maxLength: 255
              description: Why these emails are blocked.
              example: Repeated spam bookings
          required:
            - emails
    blocked_email_create_response:
      type: object
      properties:
        blocked_emails:
          type: array
          items:
            $ref: '#/components/schemas/blocked_email'
          description: >-
            Each distinct requested email once, sorted by address, whether newly
            blocked or already blocked.
    blocked_email:
      type: object
      properties:
        id:
          type: string
          description: Unique identifier for the blocked email.
          example: 3f1c2d4e-5a6b-4c7d-8e9f-0a1b2c3d4e5f
        email:
          type: string
          description: >-
            The blocked email, stored lowercased and without `+tags` (and
            without dots for Gmail).
          example: spammer@example.com
        note:
          type: string
          nullable: true
          description: Why the email was blocked.
          example: Repeated spam bookings
        created_at:
          type: string
          format: date-time
          description: When the email was blocked.
          example: '2026-10-27T10:15:30.000Z'

````

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