Reply to customer
Send a reply to the customer, or save it as a draft for you to send.
POST https://cotlet.dev/api/v1/freescout/conversations/{conversation_id}/customer/replies
Writes a reply under your name. With draft set to true the text is saved in FreeScout as a draft, nothing leaves FreeScout, and you finish it with Edit Draft. Without draft the email goes to the customer at once. status_after sets the status once the reply is sent, like the Send dropdown. By default you confirm each call; you can switch that off for this tool.
Parameters
| Name | Type | Description |
|---|---|---|
| conversation_id integer required | integer | Conversation ID from list_conversations or get_conversation. It is not the #number shown in the list. |
| body string required | string | Text of the reply. |
| draft boolean | boolean | true saves a draft and sends nothing. Default false. |
| status_after string | string | active, pending or closed. Leave out to keep what the Send dropdown shows by default. |
Request
curl -X POST https://cotlet.dev/api/v1/freescout/conversations/4821/customer/replies \
-H "Authorization: Bearer $COTLET_API_KEY" \
-H "Content-Type: application/json" \
-d '{"body":"Hi Lena, thanks for flagging this. The VAT number on your October invoice is a template error on our side. A corrected invoice is on its way today.","draft":true}' result = client.call("freescout", "reply_to_customer", {"conversation_id":4821,"body":"Hi Lena, thanks for flagging this. The VAT number on your October invoice is a template error on our side. A corrected invoice is on its way today.","draft":True}) const result = await cotlet.call('freescout', 'reply_to_customer', {"conversation_id":4821,"body":"Hi Lena, thanks for flagging this. The VAT number on your October invoice is a template error on our side. A corrected invoice is on its way today.","draft":true}); cotlet call freescout reply_to_customer --data '{"conversation_id":4821,"body":"Hi Lena, thanks for flagging this. The VAT number on your October invoice is a template error on our side. A corrected invoice is on its way today.","draft":true}' Example response
{
"conversation_id": 4821,
"thread_type": "message",
"state": "draft",
"url": "https://support.yourcompany.com/conversation/4821"
}