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

# Forward Message

> Forward an existing message to another contact or group

## Description

**⚠️ This endpoint is not yet implemented.**

This endpoint will allow forwarding existing messages to other contacts or groups on WhatsApp, maintaining the original format and content of the message.

## Body

```json theme={null}
{
  "sessionId": "my-session",
  "jid": "5511999999999@s.whatsapp.net",
  "messageId": "3EB0XXXXXX",
  "fromJid": "5511999999999@s.whatsapp.net"
}
```

### Body Parameters

| Property    | Type     | Required | Description                                                                                                               |
| ----------- | -------- | -------- | ------------------------------------------------------------------------------------------------------------------------- |
| `sessionId` | `string` | ✅ Yes    | Authenticated session ID that will forward the message                                                                    |
| `jid`       | `string` | ✅ Yes    | Recipient identifier (WhatsApp JID). Format: `5511999999999@s.whatsapp.net` for contacts or `120363XXXXX@g.us` for groups |
| `messageId` | `string` | ✅ Yes    | Message ID to be forwarded                                                                                                |
| `fromJid`   | `string` | ✅ Yes    | Source chat JID of the message                                                                                            |

<ResponseExample>
  ```json Success Response theme={null}
  {
    "success": true,
    "messageId": "3EB0XXXXXX"
  }
  ```
</ResponseExample>

## Status Codes

* `200` - Message forwarded successfully
* `400` - Invalid parameters
* `401` - Unauthorized session
* `404` - Session not found
* `501` - Not implemented

## Usage Example

<CodeGroup>
  ```bash cURL theme={null}
  curl -X POST https://api.wappfy.com.br/api/forwardMessage \
    -H "Content-Type: application/json" \
    -d '{
      "sessionId": "my-session",
      "jid": "5511999999999@s.whatsapp.net",
      "messageId": "3EB0XXXXXX",
      "fromJid": "5511888888888@s.whatsapp.net"
    }'
  ```

  ```javascript JavaScript theme={null}
  const response = await fetch('https://api.wappfy.com.br/api/forwardMessage', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json'
    },
    body: JSON.stringify({
      sessionId: 'my-session',
      jid: '5511999999999@s.whatsapp.net',
      messageId: '3EB0XXXXXX',
      fromJid: '5511888888888@s.whatsapp.net'
    })
  });
  const data = await response.json();
  console.log(data);
  ```

  ```python Python theme={null}
  import requests

  response = requests.post(
      'https://api.wappfy.com.br/api/forwardMessage',
      json={
          'sessionId': 'my-session',
          'jid': '5511999999999@s.whatsapp.net',
          'messageId': '3EB0XXXXXX',
          'fromJid': '5511888888888@s.whatsapp.net'
      }
  )
  data = response.json()
  print(data)
  ```
</CodeGroup>


## OpenAPI

````yaml viewer-en.json post /api/forwardMessage
openapi: 3.1.0
info:
  title: Wappfy - WhatsApp HTTP API
  version: '2.0'
  contact: {}
servers:
  - url: https://{host}
    description: Customizable Server
    variables:
      host:
        default: api.wappfy.com.br
        description: Server URL (e.g., api.wappfy.com.br or your-server.com)
security:
  - api_key: []
tags:
  - name: 🖥️ Sessions
    description: Control WhatsApp sessions (accounts)
  - name: 🔑 Auth
    description: Authentication
  - name: 🆔 Profile
    description: Your profile information
  - name: 🖼️ Screenshot
    description: Get WhatsApp screenshot and display QR code
  - name: 📤 Chatting
    description: Conversation methods
  - name: 📢 Channels
    description: Channels (newsletters) methods
  - name: 🟢 Status
    description: Status (aka stories) methods
  - name: 💬 Chats
    description: Conversations methods
  - name: 👤 Contacts
    description: |-
      Contacts methods.<br>
                      Use phone number (without +) or phone number and `@c.us` at the end as `contactId`.<br>
                      E.g: `12312312310` OR `12312312310@c.us`<br>
  - name: 👥 Groups
    description: Groups methods.<br>
  - name: ✅ Presence
    description: Presence information
  - name: 📅 Events
    description: Event Message
  - name: 🏷️ Labels
    description: Labels - available only for WhatsApp Business accounts
  - name: 🔍 Observability
    description: Other methods
  - name: 🗄️ Storage
    description: Storage methods
externalDocs:
  description: Wappfy - WhatsApp API
  url: https://docs.wappfy.com.br/
paths:
  /api/forwardMessage:
    post:
      tags:
        - 📤 Chatting
      operationId: ChattingController_forwardMessage
      parameters: []
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/MessageForwardRequest'
      responses:
        '201':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WAMessage'
      security:
        - api_key: []
components:
  schemas:
    MessageForwardRequest:
      type: object
      properties:
        chatId:
          type: string
          example: 5511999999999@c.us
        messageId:
          type: string
          example: false_11111111111@c.us_AAAAAAAAAAAAAAAAAAAA
        session:
          type: string
          example: my-session
          description: Session name (instanceName)
      required:
        - chatId
        - messageId
        - session
    WAMessage:
      type: object
      properties:
        id:
          type: string
          description: Message ID
          example: false_11111111111@c.us_AAAAAAAAAAAAAAAAAAAA
        timestamp:
          type: number
          description: Unix timestamp of when the message was created
          example: 1666943582
        from:
          type: string
          description: Chat ID to which this message was sent
          example: 5511999999999@c.us
        fromMe:
          type: boolean
          description: Indicates if the message was sent by the current user
        source:
          enum:
            - api
            - app
          type: string
          description: >-
            The device that sent the message - either API or APP. Available in
            events (webhooks/websockets) only and only "fromMe: true" messages.
          example: api
        to:
          type: string
          description: >-
            * ID for who this message is for.

            * If the message is sent by the current user, it will be the Chat to
            which the message is being sent.

            * If the message is sent by another user, it will be the ID for the
            current user.
          example: 5511999999999@c.us
        participant:
          type: string
          description: For groups - participant who sent the message
        body:
          type: string
          description: Message content
        hasMedia:
          type: boolean
          description: Indicates if the message has media available for download
        media:
          description: Message media object, if any and downloaded
          allOf:
            - $ref: '#/components/schemas/WAMedia'
        ack:
          enum:
            - -1
            - 0
            - 1
            - 2
            - 3
            - 4
          type: number
          description: Message acknowledgement (ACK) status
        ackName:
          type: string
          description: Message acknowledgement status name
        author:
          type: string
          description: >-
            If the message was sent to a group, this field will contain the user
            who sent the message
        location:
          description: Location information contained in the message
          allOf:
            - $ref: '#/components/schemas/WALocation'
        vCards:
          description: List of vCards contained in the message
          type: array
          items:
            type: string
        _data:
          type: object
          description: >-
            Message in raw WhatsApp format. May change at any time, use with
            caution!
        replyTo:
          $ref: '#/components/schemas/ReplyToMessage'
      required:
        - id
        - timestamp
        - from
        - fromMe
        - source
        - to
        - participant
        - body
        - hasMedia
        - mediaUrl
        - ack
        - ackName
    WAMedia:
      type: object
      properties:
        url:
          type: string
          description: Media URL in the message, if any
          example: >-
            http://localhost:3000/api/files/false_11111111111@c.us_AAAAAAAAAAAAAAAAAAAA.oga
        mimetype:
          type: string
          description: Media MIME type in the message
          example: audio/jpeg
        filename:
          type: string
          description: Original media file name
          example: example.pdf
        s3:
          description: Media S3 attributes if you are using S3 storage
          allOf:
            - $ref: '#/components/schemas/S3MediaData'
        error:
          type: object
          description: Error message when downloading media
          example: null
    WALocation:
      type: object
      properties:
        description:
          type: string
        latitude:
          type: string
        longitude:
          type: string
      required:
        - latitude
        - longitude
    ReplyToMessage:
      type: object
      properties:
        id:
          type: string
          description: Message ID
          example: AAAAAAAAAAAAAAAAAAAA
        participant:
          type: string
          example: 5511999999999@c.us
        body:
          type: string
          example: Hello!
        _data:
          type: object
          description: Raw data from reply's message
      required:
        - id
    S3MediaData:
      type: object
      properties:
        Bucket:
          type: string
          description: Nome do bucket S3
          example: my-bucket
        Key:
          type: string
          description: S3 bucket object key
          example: default/false_11111111111@c.us_AAAAAAAAAAAAAAAAAAAA.oga
      required:
        - Bucket
        - Key
  securitySchemes:
    api_key:
      type: apiKey
      in: header
      name: apikey
      description: Your Wappfy API key (get it at dash.wappfy.com.br)

````