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

# Send a message in a conversation



## OpenAPI

````yaml /api-reference/openapi.json post /v1/inbox/conversations/{id}/messages
openapi: 3.0.0
info:
  title: PlugKit API
  description: >-
    One API to publish, schedule and message across Instagram, WhatsApp, TikTok,
    Telegram, YouTube and X.
  version: 1.0.0
  contact: {}
servers: []
security: []
tags: []
paths:
  /v1/inbox/conversations/{id}/messages:
    post:
      tags:
        - inbox
      summary: Send a message in a conversation
      operationId: MessagesController_sendMessage[0]
      parameters:
        - name: id
          required: true
          in: path
          schema:
            type: string
        - name: Idempotency-Key
          in: header
          description: >-
            Optional key making this request safely retryable: replaying the
            same key with the same body returns the original response instead of
            executing twice. Keys are kept for 24 h.
          required: false
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SendMessageDto'
      responses:
        '201':
          description: ''
      security:
        - api-key: []
components:
  schemas:
    SendMessageDto:
      type: object
      properties:
        text:
          type: string
          description: >-
            Text content of the message. Optional when `template` is given — the
            template carries the content, and the text is then only what the
            inbox shows.
        template:
          description: >-
            WhatsApp only: send an approved template instead of free-form text.
            Required past the 24h messaging window; ignored by other platforms.
          allOf:
            - $ref: '#/components/schemas/MessageTemplateDto'
      required:
        - text
    MessageTemplateDto:
      type: object
      properties:
        name:
          type: string
          example: order_update
        language:
          type: string
          example: fr
          description: Language code of the approved template (default en_US)
        variables:
          description: Values for the {{1}}, {{2}}… placeholders of the body, in order
          type: array
          items:
            type: string
        components:
          description: >-
            Raw Meta components (header, buttons). Escape hatch: overrides
            `variables`.
          type: array
          items:
            type: object
      required:
        - name
  securitySchemes:
    api-key:
      scheme: bearer
      bearerFormat: sk_...
      type: http

````