curl -X POST "https://app.famulor.de/api/user/whatsapp/send" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"sender_id": 12,
"template_id": 45,
"recipient_phone": "+1234567890",
"recipient_name": "John Doe",
"variables": {
"1": "John",
"2": "January 15, 2026",
"3": "2:00 PM"
}
}'
curl -X POST "https://app.famulor.de/api/user/whatsapp/send" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: "application/json" \
-d '{
"sender_id": 12,
"template_id": 46,
"recipient_phone": "+1234567890"
}'
const response = await fetch(
'https://app.famulor.de/api/user/whatsapp/send',
{
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
sender_id: 12,
template_id: 45,
recipient_phone: '+1234567890',
recipient_name: 'John Doe',
variables: {
'1': 'John',
'2': 'January 15, 2026',
'3': '2:00 PM'
}
})
}
);
const data = await response.json();
console.log(data);
import requests
response = requests.post(
'https://app.famulor.de/api/user/whatsapp/send',
headers={
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
json={
'sender_id': 12,
'template_id': 45,
'recipient_phone': '+1234567890',
'recipient_name': 'John Doe',
'variables': {
'1': 'John',
'2': 'January 15, 2026',
'3': '2:00 PM'
}
}
)
print(response.json())
{
"success": true,
"conversation_id": 1234,
"message_id": 567,
"whatsapp_message_id": 890,
"message_sid": "SMxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"status": "queued"
}
{
"success": false,
"error": "Insufficient balance. Please top up your account.",
"error_code": "INSUFFICIENT_BALANCE"
}
{
"success": false,
"error": "Sender not found or does not belong to you",
"error_code": "SENDER_NOT_FOUND"
}
{
"success": false,
"error": "Template not found or does not belong to this sender",
"error_code": "TEMPLATE_NOT_FOUND"
}
{
"success": false,
"error": "Template is not approved. Current status: pending",
"error_code": "TEMPLATE_NOT_APPROVED"
}
{
"success": false,
"error": "Invalid phone number format. Use E.164 format (e.g., +14155551234).",
"error_code": "INVALID_PHONE"
}
{
"success": false,
"error": "Sender is not online. Current status: Offline",
"error_code": "SENDER_OFFLINE"
}
WhatsApp-Template-Nachricht senden
WhatsApp-Template-Nachrichten über Famulor versenden
POST
/
api
/
user
/
whatsapp
/
send
curl -X POST "https://app.famulor.de/api/user/whatsapp/send" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"sender_id": 12,
"template_id": 45,
"recipient_phone": "+1234567890",
"recipient_name": "John Doe",
"variables": {
"1": "John",
"2": "January 15, 2026",
"3": "2:00 PM"
}
}'
curl -X POST "https://app.famulor.de/api/user/whatsapp/send" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: "application/json" \
-d '{
"sender_id": 12,
"template_id": 46,
"recipient_phone": "+1234567890"
}'
const response = await fetch(
'https://app.famulor.de/api/user/whatsapp/send',
{
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
sender_id: 12,
template_id: 45,
recipient_phone: '+1234567890',
recipient_name: 'John Doe',
variables: {
'1': 'John',
'2': 'January 15, 2026',
'3': '2:00 PM'
}
})
}
);
const data = await response.json();
console.log(data);
import requests
response = requests.post(
'https://app.famulor.de/api/user/whatsapp/send',
headers={
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
json={
'sender_id': 12,
'template_id': 45,
'recipient_phone': '+1234567890',
'recipient_name': 'John Doe',
'variables': {
'1': 'John',
'2': 'January 15, 2026',
'3': '2:00 PM'
}
}
)
print(response.json())
{
"success": true,
"conversation_id": 1234,
"message_id": 567,
"whatsapp_message_id": 890,
"message_sid": "SMxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"status": "queued"
}
{
"success": false,
"error": "Insufficient balance. Please top up your account.",
"error_code": "INSUFFICIENT_BALANCE"
}
{
"success": false,
"error": "Sender not found or does not belong to you",
"error_code": "SENDER_NOT_FOUND"
}
{
"success": false,
"error": "Template not found or does not belong to this sender",
"error_code": "TEMPLATE_NOT_FOUND"
}
{
"success": false,
"error": "Template is not approved. Current status: pending",
"error_code": "TEMPLATE_NOT_APPROVED"
}
{
"success": false,
"error": "Invalid phone number format. Use E.164 format (e.g., +14155551234).",
"error_code": "INVALID_PHONE"
}
{
"success": false,
"error": "Sender is not online. Current status: Offline",
"error_code": "SENDER_OFFLINE"
}
WhatsApp-Template-Nachricht senden
Eine WhatsApp-Nachricht mit einem freigegebenen Template sendenDieser Endpunkt sendet eine WhatsApp-Nachricht mithilfe eines vorab freigegebenen Templates. Template-Nachrichten sind erforderlich, um eine Konversation mit einem Nutzer erstmals zu starten oder um ihn außerhalb des 24-Stunden-Messaging-Fensters zu kontaktieren.
This endpoint is rate-limited to 5 requests per second per user.
Anfrage-Body
integer
erforderlich
Die ID des WhatsApp-Senders, von dem gesendet werden soll (erhalten über WhatsApp-Sender abrufen)
integer
erforderlich
Die ID des zu verwendenden Nachrichtentemplates (erhalten über WhatsApp-Templates abrufen)
string
erforderlich
Die Telefonnummer des Empfängers im internationalen Format (z.B.
+1234567890)string
Der Name des Empfängers, max. 255 Zeichen (für Konversations-Tracking und CRM-Zwecke)
object
Key-Value-Paare für Template-Variablen. Keys müssen den Variablennamen aus dem Template entsprechen. Wenn das Template Variablen
{{1}}, {{2}} usw. hat, gib sie als {\"1\": \"value1\", \"2\": \"value2\"} oder mit den benannten Keys aus dem variables-Array des Templates an.Antwort-Felder
boolean
Ob die Nachricht erfolgreich gesendet wurde
integer
Die ID der (neuen oder bestehenden) Konversation, die mit dieser Nachricht verknüpft ist
integer
Die ID des Konversations-Nachrichteneintrags
integer
Die ID des WhatsApp-Nachrichteneintrags
string
Die Twilio Message SID zur Sendungsverfolgung
string
Der initiale Zustellstatus der Nachricht (z.B.
queued, sent)Fehler-Antworten
curl -X POST "https://app.famulor.de/api/user/whatsapp/send" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"sender_id": 12,
"template_id": 45,
"recipient_phone": "+1234567890",
"recipient_name": "John Doe",
"variables": {
"1": "John",
"2": "January 15, 2026",
"3": "2:00 PM"
}
}'
curl -X POST "https://app.famulor.de/api/user/whatsapp/send" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: "application/json" \
-d '{
"sender_id": 12,
"template_id": 46,
"recipient_phone": "+1234567890"
}'
const response = await fetch(
'https://app.famulor.de/api/user/whatsapp/send',
{
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
sender_id: 12,
template_id: 45,
recipient_phone: '+1234567890',
recipient_name: 'John Doe',
variables: {
'1': 'John',
'2': 'January 15, 2026',
'3': '2:00 PM'
}
})
}
);
const data = await response.json();
console.log(data);
import requests
response = requests.post(
'https://app.famulor.de/api/user/whatsapp/send',
headers={
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
json={
'sender_id': 12,
'template_id': 45,
'recipient_phone': '+1234567890',
'recipient_name': 'John Doe',
'variables': {
'1': 'John',
'2': 'January 15, 2026',
'3': '2:00 PM'
}
}
)
print(response.json())
{
"success": true,
"conversation_id": 1234,
"message_id": 567,
"whatsapp_message_id": 890,
"message_sid": "SMxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"status": "queued"
}
{
"success": false,
"error": "Insufficient balance. Please top up your account.",
"error_code": "INSUFFICIENT_BALANCE"
}
{
"success": false,
"error": "Sender not found or does not belong to you",
"error_code": "SENDER_NOT_FOUND"
}
{
"success": false,
"error": "Template not found or does not belong to this sender",
"error_code": "TEMPLATE_NOT_FOUND"
}
{
"success": false,
"error": "Template is not approved. Current status: pending",
"error_code": "TEMPLATE_NOT_APPROVED"
}
{
"success": false,
"error": "Invalid phone number format. Use E.164 format (e.g., +14155551234).",
"error_code": "INVALID_PHONE"
}
{
"success": false,
"error": "Sender is not online. Current status: Offline",
"error_code": "SENDER_OFFLINE"
}
Notes
- Template messages must use approved templates. Templates with
pendingorrejectedstatus will fail. - The sender must be
online. Offline senders cannot send messages. - Message costs are automatically deducted from your account balance (credits for tenant users, minutes for direct users).
- After sending a template message, a 24-hour messaging window opens. During this window, you can send freeform messages without needing a template.
- If a conversation already exists with the recipient, the message is added to the existing conversation.
- Rate limit: 5 requests per second per user.