What the model is told
Create a new contact in Freshworks CRM. Confirm the name, email address and phone number with the customer first, and check with Find Freshworks CRM Contact by Email that they do not already exist. Returns the new contact, including its ID.
Request
POSThttps://YOUR_DOMAIN.myfreshworks.com/crm/sales/api/contacts
Headers
AuthorizationToken token=YOUR_FRESHWORKS_API_KEYContent-Typeapplication/json
Body
{
"contact": {
"first_name": "{{firstName}}",
"last_name": "{{lastName}}",
"emails": [
{
"value": "{{email}}",
"is_primary": true
}
],
"mobile_number": "{{phone}}"
}
}Parameters
firstName stringThe customer's first name.lastName stringThe customer's last name.email stringThe customer's email address.phone stringThe customer's mobile number in international format.
Engage payload
{
"source": "VOICE_AI",
"tool": {
"id": "1e9d1e97-9208-4c6b-81da-e480dde17cad",
"type": "HTTP_REQUEST",
"label": "Create Freshworks CRM Contact",
"name": "create_freshworks_crm_contact",
"customName": false,
"description": "Create a new contact in Freshworks CRM. Confirm the name, email address and phone number with the customer first, and check with Find Freshworks CRM Contact by Email that they do not already exist. Returns the new contact, including its ID.",
"parameters": [
{
"name": "firstName",
"type": "string",
"description": "The customer's first name."
},
{
"name": "lastName",
"type": "string",
"description": "The customer's last name."
},
{
"name": "email",
"type": "string",
"description": "The customer's email address."
},
{
"name": "phone",
"type": "string",
"description": "The customer's mobile number in international format."
}
],
"config": {
"endpoint": {
"method": "POST",
"url": "https://YOUR_DOMAIN.myfreshworks.com/crm/sales/api/contacts"
},
"headers": [
{
"name": "Authorization",
"value": "Token token=YOUR_FRESHWORKS_API_KEY"
},
{
"name": "Content-Type",
"value": "application/json"
}
],
"body": "{\n \"contact\": {\n \"first_name\": \"{{firstName}}\",\n \"last_name\": \"{{lastName}}\",\n \"emails\": [\n {\n \"value\": \"{{email}}\",\n \"is_primary\": true\n }\n ],\n \"mobile_number\": \"{{phone}}\"\n }\n}",
"timeout": null
}
}
}IDs are regenerated on every copy.