Senden Sie WhatsApp-Nachrichten, Vorlagen und Medien, verwalten Sie Unterhaltungen und Kontakte und lesen Sie Ihren Nachrichtenverlauf — über HTTPS und JSON.
Melden Sie sich als Kontoinhaber im LetsBot-Panel an.
Öffnen Sie API → Authentifizierungsdaten.
Kopieren Sie den Schlüssel der Nummer, die senden soll, und senden Sie ihn in diesem Header: Authorization: Bearer <lb_api_key>
Die API funktioniert während der kostenlosen Testphase oder mit dem Add-on API Access. Jede verbundene Nummer hat einen eigenen Schlüssel, und der Schlüssel bestimmt, welche Nummer sendet.
Die CRM-API nutzt stattdessen einen Arbeitsbereichsschlüssel: Integrationen → Zapier → API-Schlüssel, mit aktiviertem crm-Bereich. X-Zapier-Api-Key: <key>
Anfragelimits
1.000 Anfragen pro Minute je API-Schlüssel. Darüber erhalten Sie 429 mit einem Retry-After-Header.
Fehler
JSON with Status: false and a Message. 401 means a missing or wrong key; 402 means the subscription or API add-on is not active. Validation failures are not uniform by default: most endpoints answer HTTP 202 with "Status": 0 and the first error in Message (a historic contract, for example message/send without a body), and the Live Chat endpoints answer 422 with "message": "error". We recommend strict validation: send the header X-LetsBot-Validation: strict (or Prefer: validation=strict) and those endpoints answer HTTP 422 with {"message": ..., "errors": {...}} listing every failing field. Without the header nothing changes. Read Status in the body, not only the HTTP code. Each endpoint lists its own responses.
Statuscodes auf einen Blick
Status
Bedeutung
Was tun
202 "Status": 0
Die Validierung hat die Anfrage abgelehnt (Standardmodus). Die Antwort enthält "Status": 0 und den ersten Fehler.
Lesen Sie Message. Senden Sie X-LetsBot-Validation: strict, um 422 mit jedem fehlerhaften Feld zu erhalten.
401 lb_api_key Incorrect
Der API-Schlüssel fehlt oder ist falsch.
Senden Sie Authorization: Bearer mit dem Schlüssel aus API → Authentifizierungsdaten.
402 SUBSCRIPTION_EXPIRED · API_ADDON_REQUIRED
Das Abonnement ist abgelaufen oder der Tarif enthält kein API-Access-Add-on.
Verlängern Sie das Abonnement oder fügen Sie im Panel das Add-on API Access hinzu.
403 No tenant associated with this channel
Der Schlüssel gehört zu keinem aktiven Arbeitsbereich, oder die Aktion ist nicht erlaubt.
Prüfen Sie, ob Sie den richtigen Schlüssel verwenden; wenden Sie sich sonst an den Support.
Eine Anfrage mit demselben Idempotency-Key läuft noch, oder ihr Ergebnis ist unbekannt.
Warten Sie die Retry-After-Sekunden und wiederholen Sie mit demselben Schlüssel, oder prüfen Sie den Nachrichtenstatus.
422 errors{} · idempotency_key_reused
Die strenge Validierung ist fehlgeschlagen, oder ein Idempotency-Key wurde für eine andere Anfrage wiederverwendet.
Korrigieren Sie die in errors genannten Felder oder nutzen Sie für eine neue Nachricht einen neuen Schlüssel.
429 Retry-After · automation_daily_limit_reached
Zu viele Anfragen, oder das tägliche Sendelimit des Arbeitsbereichs ist erreicht.
Warten Sie die Retry-After-Sekunden. Das Tageslimit lässt sich im Panel ändern.
Idempotente Wiederholungen
Fügen Sie einem Versand einen Idempotency-Key-Header hinzu und wiederholen Sie ihn bei jedem neuen Versuch: Die Nachricht wird nie doppelt gesendet. Die genauen Regeln:
Retrying a send after a timeout or a dropped connection can deliver the message twice. To prevent that, send an Idempotency-Key: <your-unique-id> header on the original request and repeat the same key on every retry of it. It works on every endpoint that sends a message, forwards a message or shares a catalog. A key can be any string (a UUID works well); it is scoped to your workspace and lasts 24 hours from first use. Without the header nothing changes.
Retry of a request that was sent: the original response is returned again with the header Idempotent-Replayed: true. Nothing is sent a second time.
Same key, different request (another phone, text, file, channel or endpoint): 422 with "code": "idempotency_key_reused". Nothing is sent. Use a new key for a new message.
First request still running:409 with "code": "idempotency_request_in_progress" and a Retry-After header. Retry with the same key after that many seconds to get its result.
First request failed with a 5xx:409 with "code": "idempotency_outcome_unknown". It may or may not have been sent, so nothing is sent now. Check the message status, or send with a new key.
First request was refused (a 4xx, or a body with "Status": false or 0 — including the 202 validation failure): the key is released and the retry is sent normally.
02 Ereignisse
Webhooks
LetsBot sendet einen HTTP-POST an Ihre URL, wenn eine Nachricht eingeht, sich ein Status ändert oder eine Bestellung weitergeht.
Legen Sie die URL im Panel unter API → Webhooks fest. Jede Zustellung steht unter API → Webhook-Protokolle.
Jede Zustellung ist JSON in dieser Form:
POST https://your-server.example/webhook
Content-Type: application/json
Signature: <hex HMAC-SHA256 of the raw body, key "Letsbot">
{
"event": "message_notification",
"data": { ... }
}
Der Signature-Header ist für alle Arbeitsbereiche gleich und beweist daher nicht den Absender. Fügen Sie dem Webhook einen geheimen eigenen Header hinzu und prüfen Sie ihn auf Ihrem Server.
You can send file message to phone number. You just send the URL of the message you want to send. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see documentMessage that contain file info (URL, mimetype of the file, file length, etc.) , messageTimesamp format and status of the message.
You can send Image message to phone number. You just send the URL of the message you want to send. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see imageMessage that contain image info (URL, mimetype of the image, caption of the message and more info) , messageTimesamp format and status of the message
You can send Video message to phone number. You just send the URL of the message you want to send. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see videoMessage that contain video info (URL, mimetype of the video, caption of the message and more info) , messageTimesamp format and status of the message.
You can send gif message to phone number. You just send the URL of the message you want to send. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see videoMessage that contain gif info (URL, mimetype of the video, caption of the message and more info) , messageTimesamp format and status of the message.
You can send audio message to phone number. You just send the URL of the message you want to send. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see videoMessage that contain audio info (URL, mimetype of the file, file length, seconds, etc.) , messageTimesamp format and status of the message.
You can send location message to phone number. You just send the lat&lng of location you want to send. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see locationMessage that contain location info (degreesLatitude, degreesLongitude) , messageTimesamp format and status of the message. <img src='https://content.pstmn.io/7311c6d3-8ba0-4b2c-a9dd-43a74850de55/aW1hZ2UucG5n' alt='' height='181' width='332'>
You can send ppt audio message to phone number. You need to send the URL of the file. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see audioMessage that contain audio info (url, mimetype, ppt, mediaKeyTimestamp, etc) , messageTimesamp format and status of the message.
You can send contact message to phone number. You just send the Contact phone number, the name of the contact and description (Optional). Id of the message in the key of the data of the response. In the Message of the data of the response , You can see contactMessage that contain Contact info (displyName, vcard) , messageTimesamp format and status of the message. <img src='https://content.pstmn.io/48feb9d7-ba29-4180-8a96-40c10a2225fa/aW1hZ2UucG5n' alt='' height='166' width='357'>
You can send message text to phone number. The Message Id is the id of key of data. remoteJid is the whatsapp phone account. text of extendedTextMessage is the body of the message that sent. messageTimestamp is the date of the message in timestamp format.
You can send sticker message to phone number. You need to send the URL of the sticker. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see stickerMessage that contain Sticker info (url, mimetype, mediaKey, mediaKeyTimestamp, etc) , messageTimesamp format and status of the message.
You can send sticker message to phone number. You need to send the URL of the sticker. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see reactionMessage that contain Reaction info (reaction id, remoteJid, senderTimestampMs) , messageTimesamp format and status of the message.
You can send reply on message to phone number. You need to send the body of the message and the message Id that you want to reply on it. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see extended TextMessage that contain Message reply info (text, contextInfo) , messageTimesamp format and status of the message.
Formularfelder
Feld
Beispiel
phone
{{phone}}
body
اهلا بك فى ليتس بوت تجربة ارسال رد
messageId
BAE5F2C25476F607
Beispielanfrage
curl -X POST "https://letsbot.net/api/v1/message/send/reply" \
-H "Authorization: Bearer YOUR_LB_API_KEY" \
-H "Accept: application/json" \
-F "phone=9665xxxxxxxx" \
-F "body=اهلا بك فى ليتس بوت تجربة ارسال رد" \
-F "messageId=BAE5F2C25476F607"
const response = await fetch("https://letsbot.net/api/v1/message/send/reply", {
method: "POST",
headers: {
"Authorization": "Bearer YOUR_LB_API_KEY",
"Accept": "application/json",
},
body: new URLSearchParams({
"phone": "9665xxxxxxxx",
"body": "اهلا بك فى ليتس بوت تجربة ارسال رد",
"messageId": "BAE5F2C25476F607",
}),
});
const data = await response.json();
console.log(data);
You can send mention on message to phone number or GroupId. You need to send mention phone number. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see extended TextMessage that contain Message mention info (mentionedJid, text) , messageTimesamp format and status of the message.
You can send disappearing message to phone number. You need to send body of the message and the duration of the message**(optional)** to hide after amount of time in seconds. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see extendedTextMessage in message of ephemeralMessage that contain Message info (text, expiration time in seconds) , messageTimesamp format and status of the message. <img src='https://content.pstmn.io/14312df8-9cd2-4694-85ec-d3ccbe502d32/aW1hZ2UucG5n' alt='' height='253' width='592'>
Formularfelder
Feld
Beispiel
phone
{{phone}}
body
This is a disappearing message that will disappear after X duration
duration
60
Beispielanfrage
curl -X POST "https://letsbot.net/api/v1/message/send/disappearing" \
-H "Authorization: Bearer YOUR_LB_API_KEY" \
-H "Accept: application/json" \
-F "phone=9665xxxxxxxx" \
-F "body=This is a disappearing message that will disappear after X duration" \
-F "duration=60"
const response = await fetch("https://letsbot.net/api/v1/message/send/disappearing", {
method: "POST",
headers: {
"Authorization": "Bearer YOUR_LB_API_KEY",
"Accept": "application/json",
},
body: new URLSearchParams({
"phone": "9665xxxxxxxx",
"body": "This is a disappearing message that will disappear after X duration",
"duration": "60",
}),
});
const data = await response.json();
console.log(data);
<?php
$ch = curl_init('https://letsbot.net/api/v1/message/send/disappearing');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'Authorization: Bearer YOUR_LB_API_KEY',
'Accept: application/json',
],
CURLOPT_POSTFIELDS => http_build_query([
'phone' => '9665xxxxxxxx',
'body' => 'This is a disappearing message that will disappear after X duration',
'duration' => '60',
]),
]);
$data = json_decode(curl_exec($ch), true);
curl_close($ch);
print_r($data);
import requests
response = requests.request(
"POST",
"https://letsbot.net/api/v1/message/send/disappearing",
headers={
"Authorization": "Bearer YOUR_LB_API_KEY",
"Accept": "application/json",
},
data={
"phone": "9665xxxxxxxx",
"body": "This is a disappearing message that will disappear after X duration",
"duration": "60",
},
)
print(response.json())
You can share catalog message to phone number. You need to the catalog phone number to be share and you can add more additional details(optional) like title, body, and description. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see extendedTextMessage that contain Message info (text, description, title, image if exist) , messageTimesamp format and status of the message. <img src='https://content.pstmn.io/7c8a1cae-eea4-4763-9d19-c4349f846c61/aW1hZ2UucG5n' alt='' height='250' width='268'>
Formularfelder
Feld
Beispiel
phone
{{phone}}
catalog
{{phone}}
title
This is title of catalog
body
This is body of catalog
description
This is desc of catalog
Beispielanfrage
curl -X POST "https://letsbot.net/api/v1/share/catalog" \
-H "Authorization: Bearer YOUR_LB_API_KEY" \
-H "Accept: application/json" \
-F "phone=9665xxxxxxxx" \
-F "catalog=9665xxxxxxxx" \
-F "title=This is title of catalog" \
-F "body=This is body of catalog" \
-F "description=This is desc of catalog"
const response = await fetch("https://letsbot.net/api/v1/share/catalog", {
method: "POST",
headers: {
"Authorization": "Bearer YOUR_LB_API_KEY",
"Accept": "application/json",
},
body: new URLSearchParams({
"phone": "9665xxxxxxxx",
"catalog": "9665xxxxxxxx",
"title": "This is title of catalog",
"body": "This is body of catalog",
"description": "This is desc of catalog",
}),
});
const data = await response.json();
console.log(data);
<?php
$ch = curl_init('https://letsbot.net/api/v1/share/catalog');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'Authorization: Bearer YOUR_LB_API_KEY',
'Accept: application/json',
],
CURLOPT_POSTFIELDS => http_build_query([
'phone' => '9665xxxxxxxx',
'catalog' => '9665xxxxxxxx',
'title' => 'This is title of catalog',
'body' => 'This is body of catalog',
'description' => 'This is desc of catalog',
]),
]);
$data = json_decode(curl_exec($ch), true);
curl_close($ch);
print_r($data);
import requests
response = requests.request(
"POST",
"https://letsbot.net/api/v1/share/catalog",
headers={
"Authorization": "Bearer YOUR_LB_API_KEY",
"Accept": "application/json",
},
data={
"phone": "9665xxxxxxxx",
"catalog": "9665xxxxxxxx",
"title": "This is title of catalog",
"body": "This is body of catalog",
"description": "This is desc of catalog",
},
)
print(response.json())
Get message content info with message id in phone chat number. In the data of the response , The body of the data response is the message content**. The chatName** is the phone number that receive this message. messageType is the type of the message that sent. remoteJid is the phone whatsapp account. Time is the time of the message in timestamp format. TimeFormatted is the time of the message in Format _ Dayname, Daynumber MonthName Year Hours:Min:Sec ZoneType_. There are different types of response depend on the message type. You can see Examples of the response in different types below the request.
Fetch the most recent messages of the WhatsApp session (limit, default 25). No date filter.
Channels: QR (WhatsApp Web) channels only. On an official WhatsApp Cloud API number this request answers 409 with "error_code": "USE_MESSAGES_ARCHIVE" and a ready-made use.example URL.
To read stored messages by date — incoming and outgoing, on any channel — use Message Archive → Get messages by date.
You can delete message for phone number. You need to send the message id. Id of the message in the key of the data of the response. In the data of the response you can see many options of the message (id, body, messageType, fileName if exist, author, chatName, time in timestamp format, status, etc).
You can send buttons message to phone number. You need to send the tilte(optional), body, footer(optional), caption(optional) and buttons of the message. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see buttonsMessage that contain buttons info (contentText, footerText, buttons, etc) , messageTimesamp format and status of the message. <img src='https://content.pstmn.io/2102cae4-08ae-4d22-a90a-c7b281eb68b2/aW1hZ2UucG5n' alt='' height='194 width='362'>
Formularfelder
Feld
Beispiel
phone
{{phone}}
title
test title
body
Content Of the Message
footer
Footer of the button
buttons[0][id]
1
buttons[0][title]
button type 1
buttons[0][type]
1
buttons[0][extra_data]
https://example.net
caption
test caption
Beispielanfrage
curl -X POST "https://letsbot.net/api/v1/button" \
-H "Authorization: Bearer YOUR_LB_API_KEY" \
-H "Accept: application/json" \
-F "phone=9665xxxxxxxx" \
-F "title=test title" \
-F "body=Content Of the Message" \
-F "footer=Footer of the button" \
-F "buttons[0][id]=1" \
-F "buttons[0][title]=button type 1" \
-F "buttons[0][type]=1" \
-F "buttons[0][extra_data]=https://example.net" \
-F "caption=test caption"
const response = await fetch("https://letsbot.net/api/v1/button", {
method: "POST",
headers: {
"Authorization": "Bearer YOUR_LB_API_KEY",
"Accept": "application/json",
},
body: new URLSearchParams({
"phone": "9665xxxxxxxx",
"title": "test title",
"body": "Content Of the Message",
"footer": "Footer of the button",
"buttons[0][id]": "1",
"buttons[0][title]": "button type 1",
"buttons[0][type]": "1",
"buttons[0][extra_data]": "https://example.net",
"caption": "test caption",
}),
});
const data = await response.json();
console.log(data);
You can send buttons with image message to phone number. You need to send the caption, footer(optional), images(array) and buttons(array) of the message. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see buttonsMessage that contain buttons info (imageMessage info, contenText, footerText, buttons, etc) , messageTimesamp format and status of the message.
You can send buttons with video message to phone number. You need to send the caption, footer(optional), video(array) and buttons(array) of the message. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see buttonsMessage that contain buttons info (videoMessage info, contenText, footerText, buttons, etc) , messageTimesamp format and status of the message.
You can send buttons with location message to phone number. You need to send the caption, footer(optional), lat, lng and buttons(array) of the message. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see buttonsMessage that contain buttons info (locationMessage info, contenText, footerText, buttons, etc) , messageTimesamp format and status of the message.
You can send buttons Template message to phone number. You need to send the title(optional), footer(optional), body and buttons(array , exp format in body) of the message. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see templateMessage that contain buttons info (hydratedButtons, displayText, url index, etc) , messageTimesamp format and status of the message.
You can send buttons Templatewith image message to phone number. You need to send the title(optional), footer(optional), body and buttons(array , exp format in body) of the message. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see templateMessage that contain buttons info (hydratedButtons, displayText, url index, etc) , messageTimesamp format and status of the message.
You can send buttons Templatewith document message to phone number. You need to send the title(optional), footer(optional), body and buttons(array , exp format in body) of the message. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see templateMessage that contain buttons info (hydratedButtons, displayText, url index, etc) , messageTimesamp format and status of the message.
You can send buttons Templatewith video message to phone number. You need to send the title(optional), footer(optional), body and buttons(array , exp format in body) of the message. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see templateMessage that contain buttons info (hydratedButtons, displayText, url index, etc) , messageTimesamp format and status of the message.
You can send buttons Templatewith location message to phone number. You need to send the title(optional), footer(optional), body and buttons(array , exp format in body) of the message. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see templateMessage that contain buttons info (hydratedButtons, displayText, url index, etc) , messageTimesamp format and status of the message.
You can send list message select to phone number. You need to send the body, footer, title(optional), buttonText and sections(array) of the message. Every section array has two index which is title and rows , for every rows has title, rowid and description(optional).You can see the result of the sections in image below. Id of the message in the key of the data of the response. In the Message of the data of the response , You can see listMessage that contain list message info (title, description, buttonText, listType, sections, etc) , messageTimesamp format and status of the message. <img src='https://content.pstmn.io/cd6efe52-5a20-48e2-ae2d-e9b235b089f6/aW1hZ2UucG5n' alt='' height='484' width='436'>
Formularfelder
Feld
Beispiel
phone
{{phone}}
body
Body of message
title
Tilte of message
footer
Footer of message
buttonText
Required, text on the button to view the list
sections[0][title]
Section 1 Text
sections[0][rows][0][title]
Option 1
sections[0][rows][0][rowId]
Option1
sections[0][rows][0][description]
This is description
sections[0][rows][1][title]
Option 2
sections[0][rows][1][rowId]
Option2
Beispielanfrage
curl -X POST "https://letsbot.net/api/v1/list/message" \
-H "Authorization: Bearer YOUR_LB_API_KEY" \
-H "Accept: application/json" \
-F "phone=9665xxxxxxxx" \
-F "body=Body of message" \
-F "title=Tilte of message" \
-F "footer=Footer of message" \
-F "buttonText=Required, text on the button to view the list" \
-F "sections[0][title]=Section 1 Text" \
-F "sections[0][rows][0][title]=Option 1" \
-F "sections[0][rows][0][rowId]=Option1" \
-F "sections[0][rows][0][description]=This is description" \
-F "sections[0][rows][1][title]=Option 2" \
-F "sections[0][rows][1][rowId]=Option2"
const response = await fetch("https://letsbot.net/api/v1/list/message", {
method: "POST",
headers: {
"Authorization": "Bearer YOUR_LB_API_KEY",
"Accept": "application/json",
},
body: new URLSearchParams({
"phone": "9665xxxxxxxx",
"body": "Body of message",
"title": "Tilte of message",
"footer": "Footer of message",
"buttonText": "Required, text on the button to view the list",
"sections[0][title]": "Section 1 Text",
"sections[0][rows][0][title]": "Option 1",
"sections[0][rows][0][rowId]": "Option1",
"sections[0][rows][0][description]": "This is description",
"sections[0][rows][1][title]": "Option 2",
"sections[0][rows][1][rowId]": "Option2",
}),
});
const data = await response.json();
console.log(data);
<?php
$ch = curl_init('https://letsbot.net/api/v1/list/message');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'Authorization: Bearer YOUR_LB_API_KEY',
'Accept: application/json',
],
CURLOPT_POSTFIELDS => http_build_query([
'phone' => '9665xxxxxxxx',
'body' => 'Body of message',
'title' => 'Tilte of message',
'footer' => 'Footer of message',
'buttonText' => 'Required, text on the button to view the list',
'sections[0][title]' => 'Section 1 Text',
'sections[0][rows][0][title]' => 'Option 1',
'sections[0][rows][0][rowId]' => 'Option1',
'sections[0][rows][0][description]' => 'This is description',
'sections[0][rows][1][title]' => 'Option 2',
'sections[0][rows][1][rowId]' => 'Option2',
]),
]);
$data = json_decode(curl_exec($ch), true);
curl_close($ch);
print_r($data);
import requests
response = requests.request(
"POST",
"https://letsbot.net/api/v1/list/message",
headers={
"Authorization": "Bearer YOUR_LB_API_KEY",
"Accept": "application/json",
},
data={
"phone": "9665xxxxxxxx",
"body": "Body of message",
"title": "Tilte of message",
"footer": "Footer of message",
"buttonText": "Required, text on the button to view the list",
"sections[0][title]": "Section 1 Text",
"sections[0][rows][0][title]": "Option 1",
"sections[0][rows][0][rowId]": "Option1",
"sections[0][rows][0][description]": "This is description",
"sections[0][rows][1][title]": "Option 2",
"sections[0][rows][1][rowId]": "Option2",
},
)
print(response.json())
You can add participants to the group by passing the group id (response of create group) and list of phone numbers**(array)** to add. The Jid of the response is the Whatsapp account of the participant you added.
You can change group settings by passing group id and the settings option. There are exactly 4 options in the settings. - unlocked (This group settings to allow all participants to edit their information). - announcement (This group settings to allow only admins to send messages to this group.) - not_announcement (This group settings to allow all participants to send messages to this group). - locked(This group settings are for admins only to edit its information).
Get groups list of your phone number. Data of the response contain : - participants array of numbers. - id of the group. - name of the group. - conversationTimestamp. - etc....
Get group conversation of your phone number by passing jid of the phone number. The data of the response contain : - Id of the mesage. - body. - caption. - messageType(text, file, image, etc). - author. - chatName (Phone number). - time in timestamp. - status of the message. - payload.imageMessage.url (if message is image). - body.content. - etc
Get Group Meta info of the group. - ID : of the group. - Subject : name of the group. - Subject Owner : owner Whatsapp account. - Subject Time : timestamp of the subject updated. - Size : number of the participants. - Creation : timestamp of the group creation. - Owner Phone : owner account number. - Description : description of the group. - Description Id : id of the description. - Restrict and announce. - Participants info ( id, admin) if not admin the value is null.
Official WhatsApp Cloud API numbers: served from your LetsBot workspace — every conversation with at least one message, newest last_message_date first, with cursor pagination (limit, cursor, next_cursor). Each item: id (chat id), contact_id, phone, name, platform, is_group, is_archived, is_pinned, last_message_date (ISO-8601, UTC).
QR (WhatsApp Web) numbers: unchanged — the chats of the WhatsApp session.
To read the messages themselves use Message Archive → Get messages by date (phone narrows it to one conversation).
Query-Parameter
Parameter
Pflicht
Beispiel
Beschreibung
platform
Nein
all
Optional, official numbers only. Same as on `contacts`: default is the platform of the channel whose key you use; `all` for every platform.
limit
Nein
50
Optional, official numbers only. Page size, default 50, maximum 200.
cursor
Nein
Optional, official numbers only. Pass `next_cursor` from the previous response, unchanged.
Get the conversation with one phone number from the WhatsApp session, newest first. Page with limit, then pass the last message's id as cursorId and its direction as cursorFromMe.
Channels: QR (WhatsApp Web) channels only. On an official WhatsApp Cloud API number this request answers 409 with "error_code": "USE_MESSAGES_ARCHIVE" and a ready-made use.example URL — call that instead.
To read stored messages on any channel, use Message Archive → Get messages by date with phone=<number>.
Official WhatsApp Cloud API numbers: served from your LetsBot workspace (the same contacts you see in Live Chat), with search, an incremental-sync filter (updated_since) and cursor pagination. The response says "source": "archive" and includes channel, the number whose key made the request.
QR (WhatsApp Web) numbers: unchanged — the phone's address book as the WhatsApp session reports it (id = WhatsApp id, name, notify = profile name, image when available). The filters below do not apply there.
Contacts are workspace-wide: one customer is one contact whichever of your numbers they wrote to.
Each contact (official numbers)
id — the WhatsApp chat id (<number>@s.whatsapp.net); contact_id — the LetsBot contact id.
phone — the customer's number, or null when WhatsApp only gave us a private identity (a customer who hides their number behind a username).
last_message_date, created_at, updated_at — ISO-8601, UTC.
Pagination: ordered by contact_id. Repeat the request with cursor=<next_cursor> until next_cursor is null.
Errors:422 for an invalid parameter or cursor; 401 for a missing or wrong key; 402 when the subscription or API add-on is not active.
Query-Parameter
Parameter
Pflicht
Beispiel
Beschreibung
search
Nein
Karim
Optional, at least 2 characters. Matches the contact's name, saved name, WhatsApp profile name or number.
phone
Nein
{{phone}}
Optional. One contact by number (international format, digits; a leading `+` is accepted).
updated_since
Nein
2026-09-01
Optional. Only contacts created or changed since this moment. `YYYY-MM-DD` or an ISO-8601 datetime, read in `timezone`. For an incremental sync, store the newest `updated_at` you received and pass it next time.
timezone
Nein
UTC
Optional, default `UTC`. IANA timezone used to read `updated_since`. Returned timestamps are always UTC.
include_groups
Nein
1
Optional. `1` also returns WhatsApp groups. By default only people are returned.
platform
Nein
all
Optional. Default: the platform of the channel whose key you use (WhatsApp for a WhatsApp number). `messenger`, `instagram`, `telegram`, ... for one platform, or `all`.
limit
Nein
50
Optional. Page size, default 50, maximum 200.
cursor
Nein
Optional. Pass `next_cursor` from the previous response, unchanged, to get the next page. `null` means there are no more pages.
You can get info of user business profile by passing phone number. The data of the response contain : - wid Whatsapp phone account. - description of the business. - website business. - category of the business. - business working hours if exist. - address of the business. - email of the business. - etc.
Get a contact with its labels and assigned team members. If the phone number is not a contact yet, it is created.
Required:phone.
Response:data = {id, phone, labels[], moderators[]}, plus whatsapp_bsuid, whatsapp_username and phone_available where WhatsApp usernames are on (see below).
WhatsApp usernames (only for workspaces with WhatsApp username support switched on; absent otherwise). phone keeps its meaning.
whatsapp_bsuid — Meta's ID for a customer who hides their number behind a WhatsApp username, e.g. EG.2288384708632117. Not a phone number; null when Meta sent none.
whatsapp_username — the customer's WhatsApp @username, without the @. Display only; null when none.
phone_available — false when the customer keeps their number private: do not SMS, call or store phone as a number.
Show a presence state in one chat (online, typing, recording…). Required:phone (the customer's number, e.g. 9665xxxxxxxx, or a group id xxxxxxx@g.us) and presence (one of unavailable, available, composing, recording, paused).
Get products of phone number. products of the data from response is the details for all products. Details like: - id of the product. - iamgeUrls. - reviewStauts from whatsapp exp(APPROVED(. - avaiability. - name. - description. - price. - currency - isHidden(Boolean). - etc
Get products of phone number. products of the data from response is the details for all products. Details like: - id of the product. - iamgeUrls. - reviewStauts from whatsapp exp(APPROVED(. - avaiability. - name. - description. - price. - currency - isHidden(Boolean). - etc
Get products of phone number. products of the data from response is the details for all products. Details like: - id of the product. - iamgeUrls. - reviewStauts from whatsapp exp(APPROVED(. - avaiability. - name. - description. - price. - currency - isHidden(Boolean). - etc
Get products of phone number. products of the data from response is the details for all products. Details like: - id of the product. - iamgeUrls. - reviewStauts from whatsapp exp(APPROVED(. - avaiability. - name. - description. - price. - currency - isHidden(Boolean). - etc
Get products of phone number. products of the data from response is the details for all products. Details like: - id of the product. - iamgeUrls. - reviewStauts from whatsapp exp(APPROVED(. - avaiability. - name. - description. - price. - currency - isHidden(Boolean). - etc
WhatsApp Template Messages API endpoints. These endpoints allow sending pre-approved WhatsApp template messages through the official Meta WhatsApp Business API.
Important Notes:
Templates must be pre-approved in WhatsApp Business Manager before sending
Only works with official WhatsApp Business API channels
Supports all template types: text, image, document, video, and location headers
Read stored WhatsApp conversations by date, in both directions. Works for official (Cloud API) and QR channels. Outgoing replies can also be received in real time with a message_notification webhook (panel → API → Webhooks), which covers new messages only.
Read the message archive by date — incoming and outgoing, including replies your team types in Live Chat.
Authentication:Authorization: Bearer {{lb_api_key}} (the collection's bearer auth). The key is in the panel → API → Authentication data (visible to the account owner). Requires an active subscription with the API Access add-on (or an active trial). This is not the Zapier key (lbz_...).
Every number: this endpoint reads the whole workspace, so one key returns the messages of all your numbers and channels. To read one number, add channel_id (the channel.id a message or webhook reports) or business_phone (that number's digits). WhatsApp messages record their number from 2026-09-30; older messages record it only where it could be attributed without guessing (a workspace with a single WhatsApp number), and a message that records no number is not returned under these filters.
Pagination: results are ordered oldest first by message_date, then id. When next_cursor is not null, repeat the same request adding cursor=<next_cursor> until it is null. Rows that share a timestamp are never skipped or repeated across pages.
Each message
from_me — true for messages you sent, false for messages from the customer.
sent_by — where an outgoing message came from (live_chat, bot, api, ...); null for incoming.
agent — {id, name} of the team member who typed the message; null for automated and incoming messages. Use this, not sent_by, to identify human replies.
contact — {id, phone, chat_id, name} of the customer, or null.
type — text, image, video, audio, file, template_text, ...
status / status_text — the last status we recorded for the message (Pending, Sent, Delivered, Viewed, FAILED). It is not proof of delivery on every channel.
message_date — ISO-8601 with offset, in the requested timezone.
channel — {id, global_id, phone, platform, is_official} of the workspace channel the message belongs to, when the message records it; null otherwise (never guessed). WhatsApp messages record their number from 2026-09-30.
referral — for an incoming message that started from a Click-to-WhatsApp ad, the ad it came from: {source_type, ad_id, source_url, headline, body, media_type, media_url, ctwa_clid}. source_type is always ad; ad_id is Meta's ad id (Meta calls it source_id); media_type is image or video and media_url its image, video or thumbnail URL; ctwa_clid is Meta's click id, for the Conversions API. Any field Meta did not send is null. referral is null for every other message, including everything you sent. Available on past messages too. Count leads per ad by grouping incoming messages on referral.ad_id.
Internal notes, reactions, system lines and deleted messages are not returned.
Response-time analytics: pair each incoming message with the next outgoing message for the same contact.phone whose agent is not null.
Errors:422 with {"Status": false, "Message": "..."} for invalid parameters (including a channel_id or business_phone that matches none of your channels, or the two naming different numbers); 401 for a missing or wrong key; 402 when the subscription or API add-on is not active.
Required. Start of the range. `YYYY-MM-DD` covers the whole day; a full ISO-8601 datetime (e.g. `2026-09-09T08:00:00+03:00`) is an exact, inclusive bound.
date_to
Ja
2026-09-09
Required. End of the range. `YYYY-MM-DD` covers the whole day (`date_from=date_to` is one full day); a full ISO-8601 datetime is an exact, inclusive bound. Must not be before `date_from`.
timezone
Ja
Europe/Kyiv
Optional, default `UTC`. IANA timezone used to read bare dates and to format every `message_date` (always returned with its offset).
from_me
Ja
1
Optional. `1`/`true` = outgoing only, `0`/`false` = incoming only. Omit for both directions.
sent_by
Nein
live_chat
Optional. Only messages from this source: `live_chat`, `bot`, `api`, `mcp`, `send_bulk`, `zapier`, `salla`, `zid`, `woocommerce`, `shopify`, `hubspot`, `pipedrive`, `stripe`, `magento`, `agent`, `drip`, `cart`, `system`, `ai`. `ai` (an AI assistant reply) is written only for workspaces that enabled the AI/rule split; elsewhere AI replies are `bot`, so filter on both to get every bot reply.
phone
Nein
{{phone}}
Optional. Only messages with this customer (international format, digits; a leading `+` is accepted).
channel_id
Nein
12
Optional. Only messages on this workspace channel — the `channel.id` a message or a webhook reports (one of your numbers). `422` when no channel with this id exists in the workspace.
business_phone
Nein
966501234567
Optional. Only messages on your WhatsApp number with these digits, international format (`+`, spaces and dashes are ignored). `422` when none of the workspace's WhatsApp numbers matches. Sent together with `channel_id`, both must name the same number.
limit
Nein
50
Optional. Page size, default 50, maximum 200.
cursor
Nein
Optional. Pass `next_cursor` from the previous response, unchanged, to get the next page. A `null` `next_cursor` means there are no more pages.
{
"Status": false,
"Message": "API access is not included in your current subscription. Please upgrade your plan or add the API addon.",
"error_code": "API_ADDON_REQUIRED"
}
Orders (order journey)
For merchants whose orders live in their own system (not Salla / Zid): record each order to start its order journey (automation reminders N days after the order) and send its invoice; cancel it to stop the journey.
Records an order from your own store system (not Salla / Zid) and starts its order journey: every active automation reminder on «Order placed» (panel → Automation reminders) goes to this customer N days after ordered_at — rating request, discount, marketing.
Required: order_id (letters, digits, ., _, -; max 64) and phone (international format, e.g. 966501234567). Optional: customer_name, ordered_at (ISO-8601, within the last 365 days, not in the future; default now), total, currency, order_url (https), store_name, language (ar, en, es, pt), invoice_number, invoice_url (https page) or invoice_pdf_url (https PDF), products (up to 20, each name + optional https url).
When invoice_url or invoice_pdf_url is sent, the invoice goes out at once, once per order, through your invoice templates (panel → Invoices). Recording an order sends nothing else by itself.
journey.reachable is false when this customer never wrote to you and your number is QR-linked: journey messages will not reach them (cold messages go out only from an official Cloud API number). invoice is one of not_requested, sent, skipped, failed, duplicate, off.
Answers 201 when recorded, 422 on validation errors ({"Status": false, "Message": ..., "errors": {...}}), 403 when no workspace is linked to the key, 409 while a new workspace is still being prepared.
Stops the order journey for a cancelled or refunded order: no further journey messages are sent for it. Send the same customer phone used when the order was recorded. cancelled is false when no open order matches this id and phone.
{
"Status": true,
"Message": "No further messages will be sent for this order.",
"cancelled": true
}
No open order200
{
"Status": true,
"Message": "No open order with this id and phone.",
"cancelled": false
}
Webhooks (event payloads)
LetsBot calls your URL when something happens in your workspace. Add a webhook in the panel → API → Webhooks and choose its events. Webhooks are workspace-wide: one webhook receives the events of every number and channel of the workspace.
Every delivery is a POST with the JSON body {"event": "<type>", "data": {...}} and a Signature header (HMAC-SHA256 of the body with your webhook's signing secret). Events: message_notification, ack_notification, chat_notification, label_notifications, contact_notifications, order_notifications.
Which of my numbers?message_notification (incoming messages, messages you send from LetsBot, and replies typed in the WhatsApp Business App on a Coexistence number) and ack_notification (delivery / read receipts) carry a channel object:
phone — your business number, digits only (null for Messenger / Instagram and other non-phone channels).
global_id — the stable id of the channel; id — the channel id shown in the panel.
is_official — true on the official WhatsApp Cloud API, false on a QR (WhatsApp Web) number.
channel is null when the event does not identify its channel. It is never guessed.
Which ad brought this lead?message_notification also carries referral. It is the Click-to-WhatsApp ad an incoming message came from, in the same shape as referral on GET /messages:
referral is null on every message that did not come from an ad, including messages you send. Meta attaches it to the first message of a conversation started from the ad.
channel was added on 2026-09-30 and referral on 2026-10-01; every other key of these payloads is unchanged. Ignore keys you do not know, so future additions never break your parser.
CRM
The CRM API reads and writes your LetsBot CRM: contacts, companies, deals and pipelines, tasks, activities, quotes and products, plus REST-hook webhooks for Zapier, Make and n8n. It is available once the workspace uses the CRM; until then every CRM path answers 404.
Base URL: your workspace's own domain, https://{workspace}.letsbot.net/api/v1/crm (the crm_base_url variable of this collection). It is not https://letsbot.net/api/v1.
Authentication — the crm scope. Send a workspace API key in the X-Zapier-Api-Key header (the crm_api_key variable; this folder sets the header for you). Create the key in the panel under Integrations → Zapier → API keys and tick the crm scope. The scope must be listed explicitly: a key with no scopes ("full access") and legacy OAuth tokens are refused with 403 and code: missing_scope. The channel lb_api_key (Bearer) used by the other sections does not work here. A key acts for the whole workspace and sees every CRM record, whatever the team permissions are.
Responses. Success: {"success": true, "data": ..., "meta"?: {current_page, last_page, per_page, total}}. Errors: {"success": false, "error": "<message>", "code": "<code>", "errors"?: {field: [messages]}} with code one of not_found (404), missing_scope (403), validation_failed (422), already_exists / conflict (409). A missing or unknown key answers 401. error follows Accept-Language (en, ar, es, pt).
Rate limit: 120 requests per minute per key (429 with Retry-After when exceeded); subscribing webhooks is also limited to 30 per minute.
Webhooks and signature. Subscribe with POST /hooks (or add a webhook in the panel under CRM → API & webhooks). Every delivery is a POST of {"id", "event", "object", "record_id", "occurred_at", "data", "changes"?, "previous"?} where data is the record in the same shape its GET returns, with these headers:
X-LetsBot-Signature: t=<unix seconds>,v1=<hex>, where v1 = HMAC-SHA256 of <t>.<raw body> with the subscription's signing secret (whsec_…, shown once).
X-LetsBot-Event — the event name, e.g. deal.won.
X-LetsBot-Delivery — the event id (also id in the body); use it to drop duplicates.
To verify: split the header on ,, compute hmac_sha256(secret, t + "." + rawBody), compare it with v1 in constant time, and reject a t older than 5 minutes. Answer 2xx to acknowledge. Failed deliveries are retried after 1 min, 5 min, 30 min, 2 h and 6 h; after 5 deliveries in a row fail the subscription is switched off, and an HTTP 410 answer switches it off at once.
Contacts through the CRM lists engine: search, filters, saved views, sort and pages. Scope: crm.
Response:data[] = contacts, meta = {current_page, last_page, per_page, total}.
WhatsApp usernames (only for workspaces with WhatsApp username support switched on; absent otherwise). phone keeps its meaning.
whatsapp_bsuid — Meta's ID for a customer who hides their number behind a WhatsApp username, e.g. EG.2288384708632117. Not a phone number; null when Meta sent none.
whatsapp_username — the customer's WhatsApp @username, without the @. Display only; null when none.
phone_available — false when the customer keeps their number private: do not SMS, call or store phone as a number.
{
"success": false,
"error": "This API key cannot use the CRM API. In LetsBot open Integrations → Zapier → API keys and create a key with the \"crm\" scope ticked.",
"code": "missing_scope"
}
The lists-engine catalogue for contact lists: every field with its type, whether it can be filtered or sorted, its filter operators and options (for example the lifecycle stage ids). Scope: crm.
Exact lookup by phone (any format) or email, or free text q. Send one of the three. Up to 25 matches, newest first. Scope: crm.
WhatsApp usernames (only for workspaces with WhatsApp username support switched on; absent otherwise). phone keeps its meaning.
whatsapp_bsuid — Meta's ID for a customer who hides their number behind a WhatsApp username, e.g. EG.2288384708632117. Not a phone number; null when Meta sent none.
whatsapp_username — the customer's WhatsApp @username, without the @. Display only; null when none.
phone_available — false when the customer keeps their number private: do not SMS, call or store phone as a number.
Creates a contact (WhatsApp customer) by phone. Scope: crm.
Required:phone (international format). Optional:name, email, city, country, owner_user_id, lifecycle_stage_id (see …/schema), company_id, custom_fields (keyed by field key).
A phone that already exists answers 409 with code: already_exists and that contact in data.
WhatsApp usernames (only for workspaces with WhatsApp username support switched on; absent otherwise). phone keeps its meaning.
whatsapp_bsuid — Meta's ID for a customer who hides their number behind a WhatsApp username, e.g. EG.2288384708632117. Not a phone number; null when Meta sent none.
whatsapp_username — the customer's WhatsApp @username, without the @. Display only; null when none.
phone_available — false when the customer keeps their number private: do not SMS, call or store phone as a number.
WhatsApp usernames (only for workspaces with WhatsApp username support switched on; absent otherwise). phone keeps its meaning.
whatsapp_bsuid — Meta's ID for a customer who hides their number behind a WhatsApp username, e.g. EG.2288384708632117. Not a phone number; null when Meta sent none.
whatsapp_username — the customer's WhatsApp @username, without the @. Display only; null when none.
phone_available — false when the customer keeps their number private: do not SMS, call or store phone as a number.
Only the fields sent change; same validation and audit as the panel. Same fields as Create a contact except phone. Scope: crm.
WhatsApp usernames (only for workspaces with WhatsApp username support switched on; absent otherwise). phone keeps its meaning.
whatsapp_bsuid — Meta's ID for a customer who hides their number behind a WhatsApp username, e.g. EG.2288384708632117. Not a phone number; null when Meta sent none.
whatsapp_username — the customer's WhatsApp @username, without the @. Display only; null when none.
phone_available — false when the customer keeps their number private: do not SMS, call or store phone as a number.
Logs a note on the contact's CRM timeline. Scope: crm.
Body:body (required, up to 10,000 characters), title, occurred_at (ISO 8601, default now), pinned.
JSON-Body
{
"body": "Customer asked for a delivery date before the end of the month.",
"title": "Delivery request",
"pinned": false
}
Beispielanfrage
curl -X POST "https://your-workspace.letsbot.net/api/v1/crm/contacts/42/notes" \
-H "X-Zapier-Api-Key: YOUR_WORKSPACE_API_KEY" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{
"body": "Customer asked for a delivery date before the end of the month.",
"title": "Delivery request",
"pinned": false
}'
const response = await fetch("https://your-workspace.letsbot.net/api/v1/crm/contacts/42/notes", {
method: "POST",
headers: {
"X-Zapier-Api-Key": "YOUR_WORKSPACE_API_KEY",
"Accept": "application/json",
"Content-Type": "application/json",
},
body: JSON.stringify({
"body": "Customer asked for a delivery date before the end of the month.",
"title": "Delivery request",
"pinned": false
}),
});
const data = await response.json();
console.log(data);
<?php
$ch = curl_init('https://your-workspace.letsbot.net/api/v1/crm/contacts/42/notes');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'X-Zapier-Api-Key: YOUR_WORKSPACE_API_KEY',
'Accept: application/json',
'Content-Type: application/json',
],
CURLOPT_POSTFIELDS => <<<'JSON'
{
"body": "Customer asked for a delivery date before the end of the month.",
"title": "Delivery request",
"pinned": false
}
JSON,
]);
$data = json_decode(curl_exec($ch), true);
curl_close($ch);
print_r($data);
import requests
response = requests.request(
"POST",
"https://your-workspace.letsbot.net/api/v1/crm/contacts/42/notes",
headers={
"X-Zapier-Api-Key": "YOUR_WORKSPACE_API_KEY",
"Accept": "application/json",
"Content-Type": "application/json",
},
json={
"body": "Customer asked for a delivery date before the end of the month.",
"title": "Delivery request",
"pinned": False,
},
)
print(response.json())
Antworten
Note201
{
"success": true,
"data": {
"id": 88,
"subject_type": "contact",
"subject_id": 42,
"type": "note",
"title": "Delivery request",
"body": "Customer asked for a delivery date before the end of the month.",
"details": {},
"actor_user_id": null,
"source": "api",
"pinned": false,
"occurred_at": "2026-10-08T09:30:00+03:00",
"created_at": "2026-10-08T09:30:00+03:00"
}
}
Logs a note on the company's CRM timeline. Scope: crm.
Body:body (required, up to 10,000 characters), title, occurred_at (ISO 8601, default now), pinned.
JSON-Body
{
"body": "Customer asked for a delivery date before the end of the month.",
"title": "Delivery request",
"pinned": false
}
Beispielanfrage
curl -X POST "https://your-workspace.letsbot.net/api/v1/crm/companies/7/notes" \
-H "X-Zapier-Api-Key: YOUR_WORKSPACE_API_KEY" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{
"body": "Customer asked for a delivery date before the end of the month.",
"title": "Delivery request",
"pinned": false
}'
const response = await fetch("https://your-workspace.letsbot.net/api/v1/crm/companies/7/notes", {
method: "POST",
headers: {
"X-Zapier-Api-Key": "YOUR_WORKSPACE_API_KEY",
"Accept": "application/json",
"Content-Type": "application/json",
},
body: JSON.stringify({
"body": "Customer asked for a delivery date before the end of the month.",
"title": "Delivery request",
"pinned": false
}),
});
const data = await response.json();
console.log(data);
<?php
$ch = curl_init('https://your-workspace.letsbot.net/api/v1/crm/companies/7/notes');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'X-Zapier-Api-Key: YOUR_WORKSPACE_API_KEY',
'Accept: application/json',
'Content-Type: application/json',
],
CURLOPT_POSTFIELDS => <<<'JSON'
{
"body": "Customer asked for a delivery date before the end of the month.",
"title": "Delivery request",
"pinned": false
}
JSON,
]);
$data = json_decode(curl_exec($ch), true);
curl_close($ch);
print_r($data);
import requests
response = requests.request(
"POST",
"https://your-workspace.letsbot.net/api/v1/crm/companies/7/notes",
headers={
"X-Zapier-Api-Key": "YOUR_WORKSPACE_API_KEY",
"Accept": "application/json",
"Content-Type": "application/json",
},
json={
"body": "Customer asked for a delivery date before the end of the month.",
"title": "Delivery request",
"pinned": False,
},
)
print(response.json())
Antworten
Note201
{
"success": true,
"data": {
"id": 88,
"subject_type": "company",
"subject_id": 7,
"type": "note",
"title": "Delivery request",
"body": "Customer asked for a delivery date before the end of the month.",
"details": {},
"actor_user_id": null,
"source": "api",
"pinned": false,
"occurred_at": "2026-10-08T09:30:00+03:00",
"created_at": "2026-10-08T09:30:00+03:00"
}
}
Only the fields sent change (title, pipeline_id, stage_id (see List pipelines and stages), amount, currency (3 letters), contact_id, company_id, owner_user_id, expected_close_date (YYYY-MM-DD)). A stage_id of a won or lost stage wins or loses the deal; lost also needs lost_reason_id (and optionally lost_note). Scope: crm.
Logs a note on the deal's CRM timeline. Scope: crm.
Body:body (required, up to 10,000 characters), title, occurred_at (ISO 8601, default now), pinned.
JSON-Body
{
"body": "Customer asked for a delivery date before the end of the month.",
"title": "Delivery request",
"pinned": false
}
Beispielanfrage
curl -X POST "https://your-workspace.letsbot.net/api/v1/crm/deals/15/notes" \
-H "X-Zapier-Api-Key: YOUR_WORKSPACE_API_KEY" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{
"body": "Customer asked for a delivery date before the end of the month.",
"title": "Delivery request",
"pinned": false
}'
const response = await fetch("https://your-workspace.letsbot.net/api/v1/crm/deals/15/notes", {
method: "POST",
headers: {
"X-Zapier-Api-Key": "YOUR_WORKSPACE_API_KEY",
"Accept": "application/json",
"Content-Type": "application/json",
},
body: JSON.stringify({
"body": "Customer asked for a delivery date before the end of the month.",
"title": "Delivery request",
"pinned": false
}),
});
const data = await response.json();
console.log(data);
<?php
$ch = curl_init('https://your-workspace.letsbot.net/api/v1/crm/deals/15/notes');
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'X-Zapier-Api-Key: YOUR_WORKSPACE_API_KEY',
'Accept: application/json',
'Content-Type: application/json',
],
CURLOPT_POSTFIELDS => <<<'JSON'
{
"body": "Customer asked for a delivery date before the end of the month.",
"title": "Delivery request",
"pinned": false
}
JSON,
]);
$data = json_decode(curl_exec($ch), true);
curl_close($ch);
print_r($data);
import requests
response = requests.request(
"POST",
"https://your-workspace.letsbot.net/api/v1/crm/deals/15/notes",
headers={
"X-Zapier-Api-Key": "YOUR_WORKSPACE_API_KEY",
"Accept": "application/json",
"Content-Type": "application/json",
},
json={
"body": "Customer asked for a delivery date before the end of the month.",
"title": "Delivery request",
"pinned": False,
},
)
print(response.json())
Antworten
Note201
{
"success": true,
"data": {
"id": 88,
"subject_type": "deal",
"subject_id": 15,
"type": "note",
"title": "Delivery request",
"body": "Customer asked for a delivery date before the end of the month.",
"details": {},
"actor_user_id": null,
"source": "api",
"pinned": false,
"occurred_at": "2026-10-08T09:30:00+03:00",
"created_at": "2026-10-08T09:30:00+03:00"
}
}
Logs a note, call or meeting on a contact, company or deal. Scope: crm.
Required:subject_type (contact, company, deal), subject_id, type (note, call, meeting). body is required for a note; direction (inbound, outbound) for a call. Optional:title, occurred_at, pinned, outcome (connected, no_answer, busy, voicemail, wrong_number), duration_minutes, location.
One sample event built from the newest record of that object (an empty list when there is none) — for trigger setup screens in Zapier, Make or n8n. Scope: crm.
Zapier / Make / n8n REST-hook subscribe. Scope: crm.
Fields:target_url (or url), event (or events[]), optional source (zapier, make, n8n, api) and description. Up to 50 subscriptions per workspace; at most 30 subscribe calls per minute per key.
The answer carries the signing secretonce — store it. Deliveries are signed with X-LetsBot-Signature (see the CRM section above).
JSON-Body
{
"target_url": "https://hooks.example.com/letsbot/crm",
"events": [
"deal.won",
"deal.lost"
],
"source": "api",
"description": "Sync won deals to the ERP"
}
Beispielanfrage
curl -X POST "https://your-workspace.letsbot.net/api/v1/crm/hooks" \
-H "X-Zapier-Api-Key: YOUR_WORKSPACE_API_KEY" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{
"target_url": "https://hooks.example.com/letsbot/crm",
"events": [
"deal.won",
"deal.lost"
],
"source": "api",
"description": "Sync won deals to the ERP"
}'
{
"success": false,
"error": "The URL must start with https://.",
"code": "validation_failed",
"errors": {
"url": [
"The URL must start with https://."
]
}
}
Wir verwenden Cookies, um Ihr Erlebnis zu verbessern und die Leistung der Website zu messen.
Cookie-Richtlinie
Cookie-Einstellungen
Wählen Sie, was Sie zulassen. Sie können das jederzeit über „Cookie-Einstellungen“ unten auf jeder Seite ändern.
Datenschutzerklärung
Notwendig
Erforderlich, damit die Website funktioniert und sicher bleibt: Sitzung, Formularschutz, gespeicherte Sprache und Bot-Prüfungen.
Immer aktiv
Analysen
Helfen Sie uns zu verstehen, wie Seiten genutzt werden, um sie zu verbessern – über Microsoft Clarity, das Seiteninteraktionen wie Klicks und Scrollen aufzeichnet.
Marketing
Messen, wie gut unsere Anzeigen wirken – über Google Ads, das Meta Pixel und ChatGPT-Anzeigen von OpenAI, einschließlich der Daten, die unsere Server an Meta und OpenAI senden.