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

# Send Media

> Send media message



## OpenAPI

````yaml openapi-v2 POST /message/sendMedia/{instance}
openapi: 3.0.3
info:
  title: Evolution API
  version: 2.1.1
servers:
  - url: https://{server-url}
    variables:
      server-url:
        default: evolution-example
        description: The URL of your EvolutionAPI server
    description: Your instance domain
security: []
paths:
  /message/sendMedia/{instance}:
    post:
      tags:
        - Message Controller
      summary: Send Media
      description: Send media message
      operationId: sendMedia
      parameters:
        - name: instance
          in: path
          required: true
          description: Name instance
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              required:
                - number
                - mediatype
                - mimetype
                - caption
                - media
                - fileName
              properties:
                number:
                  type: string
                  description: Number to receive the message (with country code)
                mediatype:
                  type: string
                  description: Image, video or document
                mimetype:
                  type: string
                  description: image/png
                caption:
                  type: string
                  description: Teste de caption
                media:
                  type: string
                  description: Url or base64
                fileName:
                  type: string
                  description: Image.png
                delay:
                  type: integer
                  description: Presence time in milliseconds before sending message
                linkPreview:
                  type: boolean
                  description: >-
                    Shows a preview of the target website if there's a link
                    within the message
                mentionsEveryOne:
                  type: boolean
                  description: Mentioned everyone when the message send
                mentioned:
                  type: array
                  items:
                    type: string
                    enum:
                      - '{{remoteJID}}'
                  description: Numbers to mention
                quoted:
                  type: object
                  properties:
                    key:
                      type: object
                      properties:
                        id:
                          type: string
                          description: Quoted message ID
                    message:
                      type: object
                      properties:
                        conversation:
                          type: string
                          description: Quoted message content
      responses:
        '201':
          description: Created
          content:
            application/json:
              schema:
                type: object
                properties:
                  key:
                    type: object
                    properties:
                      remoteJid:
                        type: string
                        description: The remote Jid.
                      fromMe:
                        type: boolean
                        description: Indicates whether the message was sent by the user.
                      id:
                        type: string
                        description: The ID of the message.
                    description: >-
                      The key of the message, which identifies the message in
                      the chat.
                  message:
                    type: object
                    properties:
                      imageMessage:
                        type: object
                        properties:
                          url:
                            type: string
                            description: The URL of the image.
                          mimetype:
                            type: string
                            description: The MIME type of the image.
                          caption:
                            type: string
                            description: The caption text of the image.
                          fileSha256:
                            type: string
                            description: The SHA-256 hash of the image file.
                          fileLength:
                            type: string
                            description: The length of the image file.
                          height:
                            type: integer
                            description: The height of the image.
                          width:
                            type: integer
                            description: The width of the image.
                          mediaKey:
                            type: string
                            description: The media key of the image.
                          fileEncSha256:
                            type: string
                            description: The SHA-256 hash of the encrypted image file.
                          directPath:
                            type: string
                            description: The direct path to the image.
                          mediaKeyTimestamp:
                            type: string
                            description: The timestamp of the media key.
                          jpegThumbnail:
                            type: string
                            description: The JPEG thumbnail of the image.
                          contextInfo:
                            type: object
                            description: Additional context information.
                        description: Details of the image message.
                    description: >-
                      The message content, which may include various types of
                      messages like text, images, etc.
                  messageTimestamp:
                    type: string
                    description: The timestamp of the message, represented as a string.
                  status:
                    type: string
                    description: >-
                      The status of the message, such as sent, received, or
                      pending.
                example:
                  key:
                    remoteJid: 553198296801@s.whatsapp.net
                    fromMe: true
                    id: BAE5F5A632EAE722
                  message:
                    imageMessage:
                      url: https://mmg.whatsapp.net/o1/v/t62.7118-2...
                      mimetype: image/png
                      caption: Caption text
                      fileSha256: VbCGkGBv5SZStLD5PHdkBWpQav/lNsXcY...
                      fileLength: '1305757'
                      height: 1080
                      width: 1920
                      mediaKey: aFQK9Ocw5tE7Nf0iBA42Xcb4Dee6G1k/pLL...
                      fileEncSha256: bGVtYeR3458RwC0p1tsGDNuj+vOu/...
                      directPath: /o1/v/t62.7118-24/f1/m232/up-oil...
                      mediaKeyTimestamp: '1717775573'
                      jpegThumbnail: /9j/2wBDABALDA4MChAODQ4SERATG...
                      contextInfo: {}
                  messageTimestamp: '1717775575'
                  status: PENDING
      deprecated: false
      security:
        - ApiKeyAuth: []
components:
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: apikey
      description: Your authorization key header

````