curl --request POST \
--url https://{host}/api/forwardMessage \
--header 'Content-Type: application/json' \
--header 'apikey: <api-key>' \
--data '
{
"chatId": "5511999999999@c.us",
"messageId": "false_11111111111@c.us_AAAAAAAAAAAAAAAAAAAA",
"session": "my-session"
}
'import requests
url = "https://{host}/api/forwardMessage"
payload = {
"chatId": "5511999999999@c.us",
"messageId": "false_11111111111@c.us_AAAAAAAAAAAAAAAAAAAA",
"session": "my-session"
}
headers = {
"apikey": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {apikey: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
chatId: '5511999999999@c.us',
messageId: 'false_11111111111@c.us_AAAAAAAAAAAAAAAAAAAA',
session: 'my-session'
})
};
fetch('https://{host}/api/forwardMessage', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://{host}/api/forwardMessage",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'chatId' => '5511999999999@c.us',
'messageId' => 'false_11111111111@c.us_AAAAAAAAAAAAAAAAAAAA',
'session' => 'my-session'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"apikey: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://{host}/api/forwardMessage"
payload := strings.NewReader("{\n \"chatId\": \"5511999999999@c.us\",\n \"messageId\": \"false_11111111111@c.us_AAAAAAAAAAAAAAAAAAAA\",\n \"session\": \"my-session\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("apikey", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://{host}/api/forwardMessage")
.header("apikey", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"chatId\": \"5511999999999@c.us\",\n \"messageId\": \"false_11111111111@c.us_AAAAAAAAAAAAAAAAAAAA\",\n \"session\": \"my-session\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://{host}/api/forwardMessage")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["apikey"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"chatId\": \"5511999999999@c.us\",\n \"messageId\": \"false_11111111111@c.us_AAAAAAAAAAAAAAAAAAAA\",\n \"session\": \"my-session\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"messageId": "3EB0XXXXXX"
}
Forward Message
Forward an existing message to another contact or group
curl --request POST \
--url https://{host}/api/forwardMessage \
--header 'Content-Type: application/json' \
--header 'apikey: <api-key>' \
--data '
{
"chatId": "5511999999999@c.us",
"messageId": "false_11111111111@c.us_AAAAAAAAAAAAAAAAAAAA",
"session": "my-session"
}
'import requests
url = "https://{host}/api/forwardMessage"
payload = {
"chatId": "5511999999999@c.us",
"messageId": "false_11111111111@c.us_AAAAAAAAAAAAAAAAAAAA",
"session": "my-session"
}
headers = {
"apikey": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {apikey: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
chatId: '5511999999999@c.us',
messageId: 'false_11111111111@c.us_AAAAAAAAAAAAAAAAAAAA',
session: 'my-session'
})
};
fetch('https://{host}/api/forwardMessage', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://{host}/api/forwardMessage",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'chatId' => '5511999999999@c.us',
'messageId' => 'false_11111111111@c.us_AAAAAAAAAAAAAAAAAAAA',
'session' => 'my-session'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"apikey: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://{host}/api/forwardMessage"
payload := strings.NewReader("{\n \"chatId\": \"5511999999999@c.us\",\n \"messageId\": \"false_11111111111@c.us_AAAAAAAAAAAAAAAAAAAA\",\n \"session\": \"my-session\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("apikey", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://{host}/api/forwardMessage")
.header("apikey", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"chatId\": \"5511999999999@c.us\",\n \"messageId\": \"false_11111111111@c.us_AAAAAAAAAAAAAAAAAAAA\",\n \"session\": \"my-session\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://{host}/api/forwardMessage")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["apikey"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"chatId\": \"5511999999999@c.us\",\n \"messageId\": \"false_11111111111@c.us_AAAAAAAAAAAAAAAAAAAA\",\n \"session\": \"my-session\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"messageId": "3EB0XXXXXX"
}
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
{
"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 |
{
"success": true,
"messageId": "3EB0XXXXXX"
}
Status Codes
200- Message forwarded successfully400- Invalid parameters401- Unauthorized session404- Session not found501- Not implemented
Usage Example
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"
}'
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);
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)
Authorizations
Your Wappfy API key (get it at dash.wappfy.com.br)
Body
Response
Message ID
"false_11111111111@c.us_AAAAAAAAAAAAAAAAAAAA"
Unix timestamp of when the message was created
1666943582
Chat ID to which this message was sent
"5511999999999@c.us"
Indicates if the message was sent by the current user
The device that sent the message - either API or APP. Available in events (webhooks/websockets) only and only "fromMe: true" messages.
api, app "api"
- 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.
"5511999999999@c.us"
For groups - participant who sent the message
Message content
Indicates if the message has media available for download
Message acknowledgement (ACK) status
-1, 0, 1, 2, 3, 4 Message acknowledgement status name
Message media object, if any and downloaded
Show child attributes
Show child attributes
If the message was sent to a group, this field will contain the user who sent the message
Location information contained in the message
Show child attributes
Show child attributes
List of vCards contained in the message
Message in raw WhatsApp format. May change at any time, use with caution!
Show child attributes
Show child attributes
