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

# Create a new contact note

> Create a note on a contact. `mentions` triggers @-mention notifications to the listed userIds. `attachments` accepts R2 keys returned from `POST /api/upload`.



## OpenAPI

````yaml /api-reference/openapi.yaml post /api/contact-notes
openapi: 3.0.3
info:
  title: Tether Relay and Tether API
  version: 1.0.0
  description: >-
    Route-derived OpenAPI contract generated from tether-relay backend sources.
    Regenerate with scripts/sync-openapi-from-backend.mjs.
servers:
  - url: https://your-instance.example.com
    description: Production
  - url: http://localhost:2212
    description: Local API service
security: []
tags:
  - name: AI
  - name: Applications
  - name: Approval
  - name: Auth
  - name: Automations
  - name: Calls
  - name: Campaigns
  - name: Contact Analytics
  - name: Contact Metrics
  - name: Contact Notes
  - name: Contacts
  - name: Conversation Monitor
  - name: Conversations
  - name: Departments
  - name: Email
  - name: Escalation Dashboard
  - name: Event Logs
  - name: Google Sheets
  - name: Marketplace
  - name: Messages
  - name: Notification Sounds
  - name: Notifications
  - name: Org Snapshots
  - name: Organizations
  - name: Outreach
  - name: Outreach Metrics
  - name: Outreach Sources
  - name: Pipelines
  - name: Processes
  - name: Prompts
  - name: Reminders
  - name: Sms
  - name: Templates
  - name: Traces
  - name: Training
  - name: Upload
  - name: User Snapshots
  - name: Users
  - name: Vertical
  - name: Webchats
  - name: Webhook
paths:
  /api/contact-notes:
    post:
      tags:
        - Contact Notes
      summary: Create a new contact note
      description: >-
        Create a note on a contact. `mentions` triggers @-mention notifications
        to the listed userIds. `attachments` accepts R2 keys returned from `POST
        /api/upload`.
      operationId: create_contact_note
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateContactNoteRequest'
      responses:
        '201':
          description: Contact note created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ContactNoteMutationResponse'
        '400':
          description: Validation error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ContactNotesErrorResponse'
        '404':
          description: Contact not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ContactNotesErrorResponse'
        '500':
          description: Failed to create contact note
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ContactNotesErrorResponse'
      security:
        - bearerAuth: []
components:
  schemas:
    CreateContactNoteRequest:
      type: object
      properties:
        contactId:
          type: string
          description: Contact `_id` the note is attached to.
        note:
          type: string
          description: >-
            Markdown/plain-text body of the note; may contain `@`-mention
            syntax.
        mentions:
          type: array
          items:
            type: string
          description: User `_id`s @-mentioned in the note; trigger notification pings.
        attachments:
          type: array
          items:
            type: object
            properties:
              key:
                type: string
              name:
                type: string
              size:
                type: number
              type:
                type: string
            required:
              - key
            additionalProperties: true
          description: R2 storage keys + content metadata for files attached to the note.
      required:
        - contactId
      additionalProperties: true
      example:
        contactId: 65c2d0e0f0a0b0c0d0e0f0a0
        note: '@alice please review the W2 attached.'
        mentions:
          - 65b1f0a2c3d4e5f6a7b8c9d0
        attachments:
          - key: orgs/65a0.../notes/w2.pdf
            name: w2.pdf
            size: 121200
            type: application/pdf
    ContactNoteMutationResponse:
      type: object
      properties:
        success:
          type: boolean
          enum:
            - true
        message:
          type: string
        data:
          $ref: '#/components/schemas/ContactNoteItem'
      required:
        - success
        - data
      additionalProperties: true
      example:
        success: true
        message: Contact note created
        data:
          _id: 67f0a0b0c0d0e0f0a0b0c0d0
          userId:
            _id: 65b1f0a2c3d4e5f6a7b8c9d3
            fullName: Cory Tan
            email: cory@example.com
          note: Spoke briefly; will follow up tomorrow.
          attachments: []
          reactions: []
          isEdited: false
          createdAt: '2026-05-18T14:00:00.000Z'
    ContactNotesErrorResponse:
      type: object
      description: >-
        Error envelope returned by contact-notes endpoints. May include `error`
        (raw exception message) on 500 paths.
      properties:
        success:
          type: boolean
          enum:
            - false
        message:
          type: string
        error:
          type: string
      additionalProperties: true
      example:
        success: false
        message: Contact note not found
        error: NOT_FOUND
    ContactNoteItem:
      type: object
      description: >-
        Populated note row. `userId` is populated to the user document (see
        ContactNoteAuthor).
      properties:
        _id:
          type: string
        userId:
          $ref: '#/components/schemas/ContactNoteAuthor'
        note:
          type: string
        attachments:
          type: array
          items:
            $ref: '#/components/schemas/ContactNoteAttachment'
        reactions:
          type: array
          items:
            $ref: '#/components/schemas/ContactNoteReaction'
        isEdited:
          type: boolean
        createdAt:
          type: string
          format: date-time
      additionalProperties: true
      example:
        _id: 67f0a0b0c0d0e0f0a0b0c0d0
        userId:
          _id: 65b1f0a2c3d4e5f6a7b8c9d3
          fullName: Cory Tan
          email: cory@example.com
        note: '@alice please review the W2 attached.'
        attachments:
          - name: w2.pdf
            size: 121200
            type: application/pdf
            signedUrl: https://r2.example.com/orgs/65a0.../notes/w2.pdf?token=...
        reactions:
          - emoji: 👍
            users:
              - 65b1f0a2c3d4e5f6a7b8c9d0
            count: 1
        isEdited: false
        createdAt: '2026-05-18T14:00:00.000Z'
    ContactNoteAuthor:
      type: object
      nullable: true
      properties:
        _id:
          type: string
        fullName:
          type: string
        email:
          type: string
        avatarUrl:
          type: string
          nullable: true
      additionalProperties: true
      example:
        _id: 65b1f0a2c3d4e5f6a7b8c9d3
        fullName: Cory Tan
        email: cory@example.com
        avatarUrl: https://cdn.example.com/avatars/cory.png
    ContactNoteAttachment:
      type: object
      description: >-
        Attachment row. Stored items carry `key`; list responses replace `key`
        with a short-lived `signedUrl`.
      properties:
        key:
          type: string
        name:
          type: string
        size:
          type: number
        type:
          type: string
        signedUrl:
          type: string
          format: uri
          description: Present only on GET list responses.
      additionalProperties: true
      example:
        name: w2.pdf
        size: 121200
        type: application/pdf
        signedUrl: https://r2.example.com/orgs/65a0.../notes/w2.pdf?token=...
    ContactNoteReaction:
      type: object
      properties:
        emoji:
          type: string
        users:
          type: array
          items:
            type: string
        count:
          type: integer
      required:
        - emoji
        - users
        - count
      additionalProperties: true
      example:
        emoji: 👍
        users:
          - 65b1f0a2c3d4e5f6a7b8c9d0
          - 65b1f0a2c3d4e5f6a7b8c9d1
        count: 2
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````