Post the necessary fields for the API to update message status.
PUT https://services.leadconnectorhq.com/conversations/messages/{messageId}/statusAuthorization Path parameters Body Responses 200 - Created the message conversationId (string, required): Conversation ID. Example: ABC12h2F6uBrIkfXYazb
emailMessageId (string): This contains the email message id (only for Email type). Use this ID to send inbound replies to GHL to create a threaded email. Example: rnGyqh2F6uBrIkfhFo9A
messageId (string, required): This is the main Message ID Example: t22c6DQcTDf3MjRhwf77
messageIds (string[]): When sending via the GMB channel, we will be returning list of messageIds instead of single messageId.
msg (string): Additional response message when sending a workflow message Example: Message queued successfully.
forwardData (object): Optional metadata for forwarded email
status (string, required): Message status Possible values: 'delivered', 'failed', 'pending', 'read' Example: delivered
{
"conversationId" : "ABC12h2F6uBrIkfXYazb" ,
"emailMessageId" : "rnGyqh2F6uBrIkfhFo9A" ,
"messageId" : "t22c6DQcTDf3MjRhwf77" ,
"messageIds" : [
"string"
],
"msg" : "Message queued successfully." ,
"forwardData" : {
"forwardWholeThread" : false ,
"messageId" : "t22c6DQcTDf3MjRhwf77" ,
"emailMessageId" : "rnGyqh2F6uBrIkfhFo9A" ,
"forwardToEmail" : "recipient@example.com" ,
"recipientContactId" : "DEF56h2F6uBrIkfXYacd"
},
"status" : "delivered"
}400 - Bad Request 401 - Unauthorized Example curl -X PUT 'https://services.leadconnectorhq.com/conversations/messages/YOUR_messageId/status' \
-H 'Authorization: Bearer YOUR_TOKEN' \
-H 'Version: 2021-07-28' \
-H 'Content-Type: application/json' \
-d '{
"status" : "read" ,
"emailMessageId" : "ve9EPM428h8vShlRW1KT" ,
"recipients" : [
"string"
]
}'const response = await fetch ('https://services.leadconnectorhq.com/conversations/messages/YOUR_messageId/status' , {
method : 'PUT' ,
headers : {
Authorization : `Bearer ${process.env.LEADWAY_TOKEN}` ,
Version : '2021-07-28' ,
'Content-Type' : 'application/json' ,
},
body : JSON.stringify ({"status" : "read" , "emailMessageId" : "ve9EPM428h8vShlRW1KT" , "recipients" : ["string" ]}),
});
const data = await response.json ();import os, requests
response = requests.request (
'PUT' ,
'https://services.leadconnectorhq.com/conversations/messages/YOUR_messageId/status' ,
headers ={
'Authorization' : f"Bearer {os.environ['LEADWAY_TOKEN']}" ,
'Version' : '2021-07-28' ,
'Content-Type' : 'application/json' ,
},
json ={"status" : "read" , "emailMessageId" : "ve9EPM428h8vShlRW1KT" , "recipients" : ["string" ]},
)
data = response.json ()<?php
$ch = curl_init ('https://services.leadconnectorhq.com/conversations/messages/YOUR_messageId/status' );
curl_setopt_array ($ch, [
CURLOPT_RETURNTRANSFER => true ,
CURLOPT_CUSTOMREQUEST => 'PUT' ,
CURLOPT_HTTPHEADER => [
'Authorization: Bearer ' . getenv ('LEADWAY_TOKEN' ),
'Version: 2021-07-28' ,
'Content-Type: application/json' ,
],
CURLOPT_POSTFIELDS => json_encode ({'status' : 'read' , 'emailMessageId' : 've9EPM428h8vShlRW1KT' , 'recipients' : ['string' ]}),
]);
$data = json_decode (curl_exec ($ch), true );