Add an inbound message
Post the necessary fields for the API to add a new inbound message.
POST
/
conversations
/
messages
/
inbound
Add an inbound message
curl --request POST \
--url https://services.leadconnectorhq.com/conversations/messages/inbound \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Version: <version>' \
--data '
{
"type": "SMS",
"conversationId": "ve9EPM428h8vShlRW1KT",
"conversationProviderId": "61d6d1f9cdac7612faf80753",
"attachments": [
"<string>"
],
"message": "<string>",
"html": "<string>",
"subject": "<string>",
"emailFrom": "sender@company.com",
"emailTo": "<string>",
"emailCc": [
"john1@doe.com",
"john2@doe.com"
],
"emailBcc": [
"john1@doe.com",
"john2@doe.com"
],
"emailMessageId": "<string>",
"altId": "61d6d1f9cdac7612faf80753",
"direction": [
"outbound",
"inbound"
],
"date": "2023-11-07T05:31:56Z",
"call": {
"to": "+15037081210",
"from": "+15037081210",
"status": "completed"
}
}
'const options = {
method: 'POST',
headers: {
Version: '<version>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
type: 'SMS',
conversationId: 've9EPM428h8vShlRW1KT',
conversationProviderId: '61d6d1f9cdac7612faf80753',
attachments: ['<string>'],
message: '<string>',
html: '<string>',
subject: '<string>',
emailFrom: 'sender@company.com',
emailTo: '<string>',
emailCc: ['john1@doe.com', 'john2@doe.com'],
emailBcc: ['john1@doe.com', 'john2@doe.com'],
emailMessageId: '<string>',
altId: '61d6d1f9cdac7612faf80753',
direction: ['outbound', 'inbound'],
date: '2023-11-07T05:31:56Z',
call: {to: '+15037081210', from: '+15037081210', status: 'completed'}
})
};
fetch('https://services.leadconnectorhq.com/conversations/messages/inbound', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://services.leadconnectorhq.com/conversations/messages/inbound"
payload = {
"type": "SMS",
"conversationId": "ve9EPM428h8vShlRW1KT",
"conversationProviderId": "61d6d1f9cdac7612faf80753",
"attachments": ["<string>"],
"message": "<string>",
"html": "<string>",
"subject": "<string>",
"emailFrom": "sender@company.com",
"emailTo": "<string>",
"emailCc": ["john1@doe.com", "john2@doe.com"],
"emailBcc": ["john1@doe.com", "john2@doe.com"],
"emailMessageId": "<string>",
"altId": "61d6d1f9cdac7612faf80753",
"direction": ["outbound", "inbound"],
"date": "2023-11-07T05:31:56Z",
"call": {
"to": "+15037081210",
"from": "+15037081210",
"status": "completed"
}
}
headers = {
"Version": "<version>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"success": true,
"conversationId": "ABC12h2F6uBrIkfXYazb",
"messageId": "t22c6DQcTDf3MjRhwf77",
"message": "<string>",
"contactId": "<string>",
"dateAdded": "2023-11-07T05:31:56Z",
"emailMessageId": "<string>"
}{
"statusCode": 400,
"message": "Bad Request"
}{
"statusCode": 401,
"message": "Invalid token: access token is invalid",
"error": "Unauthorized"
}Authorizations
Body
application/json
Last modified on March 8, 2026
Was this page helpful?
Add an inbound message
curl --request POST \
--url https://services.leadconnectorhq.com/conversations/messages/inbound \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Version: <version>' \
--data '
{
"type": "SMS",
"conversationId": "ve9EPM428h8vShlRW1KT",
"conversationProviderId": "61d6d1f9cdac7612faf80753",
"attachments": [
"<string>"
],
"message": "<string>",
"html": "<string>",
"subject": "<string>",
"emailFrom": "sender@company.com",
"emailTo": "<string>",
"emailCc": [
"john1@doe.com",
"john2@doe.com"
],
"emailBcc": [
"john1@doe.com",
"john2@doe.com"
],
"emailMessageId": "<string>",
"altId": "61d6d1f9cdac7612faf80753",
"direction": [
"outbound",
"inbound"
],
"date": "2023-11-07T05:31:56Z",
"call": {
"to": "+15037081210",
"from": "+15037081210",
"status": "completed"
}
}
'const options = {
method: 'POST',
headers: {
Version: '<version>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
type: 'SMS',
conversationId: 've9EPM428h8vShlRW1KT',
conversationProviderId: '61d6d1f9cdac7612faf80753',
attachments: ['<string>'],
message: '<string>',
html: '<string>',
subject: '<string>',
emailFrom: 'sender@company.com',
emailTo: '<string>',
emailCc: ['john1@doe.com', 'john2@doe.com'],
emailBcc: ['john1@doe.com', 'john2@doe.com'],
emailMessageId: '<string>',
altId: '61d6d1f9cdac7612faf80753',
direction: ['outbound', 'inbound'],
date: '2023-11-07T05:31:56Z',
call: {to: '+15037081210', from: '+15037081210', status: 'completed'}
})
};
fetch('https://services.leadconnectorhq.com/conversations/messages/inbound', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://services.leadconnectorhq.com/conversations/messages/inbound"
payload = {
"type": "SMS",
"conversationId": "ve9EPM428h8vShlRW1KT",
"conversationProviderId": "61d6d1f9cdac7612faf80753",
"attachments": ["<string>"],
"message": "<string>",
"html": "<string>",
"subject": "<string>",
"emailFrom": "sender@company.com",
"emailTo": "<string>",
"emailCc": ["john1@doe.com", "john2@doe.com"],
"emailBcc": ["john1@doe.com", "john2@doe.com"],
"emailMessageId": "<string>",
"altId": "61d6d1f9cdac7612faf80753",
"direction": ["outbound", "inbound"],
"date": "2023-11-07T05:31:56Z",
"call": {
"to": "+15037081210",
"from": "+15037081210",
"status": "completed"
}
}
headers = {
"Version": "<version>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"success": true,
"conversationId": "ABC12h2F6uBrIkfXYazb",
"messageId": "t22c6DQcTDf3MjRhwf77",
"message": "<string>",
"contactId": "<string>",
"dateAdded": "2023-11-07T05:31:56Z",
"emailMessageId": "<string>"
}{
"statusCode": 400,
"message": "Bad Request"
}{
"statusCode": 401,
"message": "Invalid token: access token is invalid",
"error": "Unauthorized"
}