VocalLabs icon

VocalLabs

Interact with VocalLabs AI Voice Calling API

Actions90

Library → Create Action

AI-generated

Summary

Create a new action in the Vocallabs library.

Inputs

  • action_name (required) — Name of the action
  • description (required) — Description of the action
  • external_curl (required) — External API CURL command
  • success_response (required) — Success response message
  • failure_response (required) — Failure response message
  • interruption_response (required) — Interruption response message
  • ref_code (required) — Reference code

Output shape

the created action object (including its generated ID and timestamps)

The response contains the full action record returned by the library API; fields not set remain empty.

Examples

Example 1: Add a new marketing campaign action

action_name: "Marketing Campaign" description: "Promote new product" external_curl: "curl -X POST https://api.example.com/campaigns" success_response: "Campaign created" failure_response: "Campaign failed" interruption_response: "Interrupted" ref_code: "MKT-001"

Example 2: Create a support ticket handling action

action_name: "Support Ticket" description: "Handle incoming tickets" external_curl: "curl -X PUT https://api.example.com/tickets" success_response: "Ticket processed" failure_response: "Ticket error" interruption_response: "User hung up" ref_code: "ST-001"

Example 3: Set up an automated voice response action

action_name: "IVR Response" description: "Play welcome message" external_curl: "curl -X GET https://api.example.com/ivr" success_response: "Message played" failure_response: "Playback failed" interruption_response: "Call transferred" ref_code: "IVR-01"

Discussion