Enviar Stories (Status)
curl --request POST \
--url https://api.wppfy.com/send/status \
--header 'Content-Type: application/json' \
--header 'token: <api-key>' \
--data '
{
"type": "text",
"text": "Novidades chegando!",
"background_color": 7,
"font": 1,
"file": "https://example.com/video.mp4",
"thumbnail": "https://example.com/thumb.jpg",
"mimetype": "video/mp4",
"track_source": "chatwoot",
"track_id": "msg_123456789"
}
'import requests
url = "https://api.wppfy.com/send/status"
payload = {
"type": "text",
"text": "Novidades chegando!",
"background_color": 7,
"font": 1,
"file": "https://example.com/video.mp4",
"thumbnail": "https://example.com/thumb.jpg",
"mimetype": "video/mp4",
"track_source": "chatwoot",
"track_id": "msg_123456789"
}
headers = {
"token": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {token: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
type: 'text',
text: 'Novidades chegando!',
background_color: 7,
font: 1,
file: 'https://example.com/video.mp4',
thumbnail: 'https://example.com/thumb.jpg',
mimetype: 'video/mp4',
track_source: 'chatwoot',
track_id: 'msg_123456789'
})
};
fetch('https://api.wppfy.com/send/status', 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://api.wppfy.com/send/status",
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([
'type' => 'text',
'text' => 'Novidades chegando!',
'background_color' => 7,
'font' => 1,
'file' => 'https://example.com/video.mp4',
'thumbnail' => 'https://example.com/thumb.jpg',
'mimetype' => 'video/mp4',
'track_source' => 'chatwoot',
'track_id' => 'msg_123456789'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"token: <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://api.wppfy.com/send/status"
payload := strings.NewReader("{\n \"type\": \"text\",\n \"text\": \"Novidades chegando!\",\n \"background_color\": 7,\n \"font\": 1,\n \"file\": \"https://example.com/video.mp4\",\n \"thumbnail\": \"https://example.com/thumb.jpg\",\n \"mimetype\": \"video/mp4\",\n \"track_source\": \"chatwoot\",\n \"track_id\": \"msg_123456789\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("token", "<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://api.wppfy.com/send/status")
.header("token", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"type\": \"text\",\n \"text\": \"Novidades chegando!\",\n \"background_color\": 7,\n \"font\": 1,\n \"file\": \"https://example.com/video.mp4\",\n \"thumbnail\": \"https://example.com/thumb.jpg\",\n \"mimetype\": \"video/mp4\",\n \"track_source\": \"chatwoot\",\n \"track_id\": \"msg_123456789\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.wppfy.com/send/status")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["token"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"type\": \"text\",\n \"text\": \"Novidades chegando!\",\n \"background_color\": 7,\n \"font\": 1,\n \"file\": \"https://example.com/video.mp4\",\n \"thumbnail\": \"https://example.com/thumb.jpg\",\n \"mimetype\": \"video/mp4\",\n \"track_source\": \"chatwoot\",\n \"track_id\": \"msg_123456789\"\n}"
response = http.request(request)
puts response.read_body{
"Id": "ABCD1234",
"content": {},
"messageTimestamp": 1672531200000,
"status": "Pending"
}{
"error": "Text too long"
}{
"error": "No session"
}{
"error": "Failed to upload media"
}Enviar Mensagem
Enviar Stories (Status)
Envia um story (status) com suporte para texto, imagem, vídeo e áudio.
Suporte a campos de rastreamento: Este endpoint também suporta track_source e track_id documentados na tag “Enviar Mensagem”.
Tipos de Status
- text: Texto com estilo e cor de fundo
- image: Imagens com legenda opcional
- video: Vídeos com thumbnail e legenda
- audio: Áudio normal ou mensagem de voz (PTT)
Cores de Fundo
- 1-3: Tons de amarelo
- 4-6: Tons de verde
- 7-9: Tons de azul
- 10-12: Tons de lilás
- 13: Magenta
- 14-15: Tons de rosa
- 16: Marrom claro
- 17-19: Tons de cinza (19 é o padrão)
Fontes (para texto)
- 0: Padrão
- 1-8: Estilos alternativos
Limites
- Texto: Máximo 656 caracteres
- Imagem: JPG, PNG, GIF
- Vídeo: MP4, MOV
- Áudio: MP3, OGG, WAV (convertido para OGG/OPUS)
Exemplo
{
"type": "text",
"text": "Novidades chegando!",
"background_color": 7,
"font": 1
}
POST
/
send
/
status
Enviar Stories (Status)
curl --request POST \
--url https://api.wppfy.com/send/status \
--header 'Content-Type: application/json' \
--header 'token: <api-key>' \
--data '
{
"type": "text",
"text": "Novidades chegando!",
"background_color": 7,
"font": 1,
"file": "https://example.com/video.mp4",
"thumbnail": "https://example.com/thumb.jpg",
"mimetype": "video/mp4",
"track_source": "chatwoot",
"track_id": "msg_123456789"
}
'import requests
url = "https://api.wppfy.com/send/status"
payload = {
"type": "text",
"text": "Novidades chegando!",
"background_color": 7,
"font": 1,
"file": "https://example.com/video.mp4",
"thumbnail": "https://example.com/thumb.jpg",
"mimetype": "video/mp4",
"track_source": "chatwoot",
"track_id": "msg_123456789"
}
headers = {
"token": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {token: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
type: 'text',
text: 'Novidades chegando!',
background_color: 7,
font: 1,
file: 'https://example.com/video.mp4',
thumbnail: 'https://example.com/thumb.jpg',
mimetype: 'video/mp4',
track_source: 'chatwoot',
track_id: 'msg_123456789'
})
};
fetch('https://api.wppfy.com/send/status', 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://api.wppfy.com/send/status",
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([
'type' => 'text',
'text' => 'Novidades chegando!',
'background_color' => 7,
'font' => 1,
'file' => 'https://example.com/video.mp4',
'thumbnail' => 'https://example.com/thumb.jpg',
'mimetype' => 'video/mp4',
'track_source' => 'chatwoot',
'track_id' => 'msg_123456789'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"token: <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://api.wppfy.com/send/status"
payload := strings.NewReader("{\n \"type\": \"text\",\n \"text\": \"Novidades chegando!\",\n \"background_color\": 7,\n \"font\": 1,\n \"file\": \"https://example.com/video.mp4\",\n \"thumbnail\": \"https://example.com/thumb.jpg\",\n \"mimetype\": \"video/mp4\",\n \"track_source\": \"chatwoot\",\n \"track_id\": \"msg_123456789\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("token", "<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://api.wppfy.com/send/status")
.header("token", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"type\": \"text\",\n \"text\": \"Novidades chegando!\",\n \"background_color\": 7,\n \"font\": 1,\n \"file\": \"https://example.com/video.mp4\",\n \"thumbnail\": \"https://example.com/thumb.jpg\",\n \"mimetype\": \"video/mp4\",\n \"track_source\": \"chatwoot\",\n \"track_id\": \"msg_123456789\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.wppfy.com/send/status")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["token"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"type\": \"text\",\n \"text\": \"Novidades chegando!\",\n \"background_color\": 7,\n \"font\": 1,\n \"file\": \"https://example.com/video.mp4\",\n \"thumbnail\": \"https://example.com/thumb.jpg\",\n \"mimetype\": \"video/mp4\",\n \"track_source\": \"chatwoot\",\n \"track_id\": \"msg_123456789\"\n}"
response = http.request(request)
puts response.read_body{
"Id": "ABCD1234",
"content": {},
"messageTimestamp": 1672531200000,
"status": "Pending"
}{
"error": "Text too long"
}{
"error": "No session"
}{
"error": "Failed to upload media"
}Autorizações
Corpo
application/json
Tipo do status
Opções disponíveis:
text, image, video, audio, myaudio, ptt Exemplo:
"text"
Texto principal ou legenda
Exemplo:
"Novidades chegando!"
Código da cor de fundo
Intervalo obrigatório:
1 <= x <= 19Exemplo:
7
Estilo da fonte (apenas para type=text)
Intervalo obrigatório:
0 <= x <= 8Exemplo:
1
URL ou Base64 do arquivo de mídia
Exemplo:
"https://example.com/video.mp4"
URL ou Base64 da miniatura (opcional para vídeos)
Exemplo:
"https://example.com/thumb.jpg"
MIME type do arquivo (opcional)
Exemplo:
"video/mp4"
Origem do rastreamento da mensagem
Exemplo:
"chatwoot"
ID para rastreamento da mensagem (aceita valores duplicados)
Exemplo:
"msg_123456789"
