Create a new action for a voice AI agent. Actions define specific behaviors and capabilities for the agent during calls.
Create a new action for a voice AI agent. Actions define specific behaviors and capabilities for the agent during calls.
http
POST https://services.leadconnectorhq.com/voice-ai/actions
Authorization
Name
Type
Required
Example
Description
Authorization
string
Yes
Bearer token generated from the Leadway portal. See Authentication.
Version
string
Yes
2021-07-28
API version.
Body
Name
Type
Required
Example
Description
agentId
string
Yes
507f1f77bcf86cd799439011
Agent ID to attach the action to
locationId
string
Yes
507f1f77bcf86cd799439012
Account ID
actionType
string
Yes
CALL_TRANSFER
Type of action Possible values: 'CALL_TRANSFER', 'DATA_EXTRACTION', 'IN_CALL_DATA_EXTRACTION', 'WORKFLOW_TRIGGER', 'SMS', 'APPOINTMENT_BOOKING', 'CUSTOM_ACTION', 'KNOWLEDGE_BASE'
name
string
Yes
Transfer to Manager
Human-readable name for this action
actionParameters
object
Yes
Action parameters - structure varies by actionType
Responses
201 - Action created successfully
id (string, required): Unique identifier for the created action Example: 507f1f77bcf86cd799439011
actionType (string, required): Type of action Possible values: 'CALL_TRANSFER', 'DATA_EXTRACTION', 'IN_CALL_DATA_EXTRACTION', 'WORKFLOW_TRIGGER', 'SMS', 'APPOINTMENT_BOOKING', 'CUSTOM_ACTION', 'KNOWLEDGE_BASE' Example: CALL_TRANSFER
name (string, required): Human-readable name for this action Example: Transfer to Manager
actionParameters (object, required): Action parameters - structure varies by actionType
json
{
"id": "507f1f77bcf86cd799439011",
"actionType": "CALL_TRANSFER",
"name": "Transfer to Manager"
}