VoiceDock Docs
ApiCampaigns

List all campaigns

Retrieve all outbound campaigns in your organization.

GET
/campaigns

Retrieve all outbound campaigns in your organization.

Authorization

BearerAuth
AuthorizationBearer <token>

API key authentication. Get your key from the dashboard.

In: header

Response Body

application/json

application/json

curl -X GET "https://example.com/campaigns"
{
  "campaigns": [
    {
      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
      "name": "Q1 Sales Outreach",
      "agent_id": "2b1e3b65-2c04-4fa2-a2d7-467901e98978",
      "status": "draft",
      "system_message_template": "You are calling {{name}} from {{company}}. Convince them to schedule a demo.",
      "schedule_start_time": "09:00:00",
      "schedule_end_time": "17:00:00",
      "timezone": "Europe/Amsterdam",
      "total_leads": 0,
      "completed_leads": 0,
      "failed_leads": 0,
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z"
    }
  ]
}
{
  "error": "Invalid API key",
  "message": "string"
}

Send control command to active call POST

Send real-time commands to an active call. The call must be in "in-progress" status. **⚠️ IMPORTANT: xAI Realtime Model Limitations** Call control has **significant limitations** when using xAI Realtime (grok-realtime-v1) due to its speech-to-speech architecture: - ❌ `inject-context`: Limited effectiveness - context may not influence responses reliably - ❌ `say`: Does not work reliably - commands often timeout or fail to trigger speech - ✅ `end-call`: Works reliably - ⚠️ `transfer`: Partial support - announcement may not work, but transfer executes **Why the limitations?** xAI Realtime is an end-to-end audio model that processes speech directly without intermediate text. It expects continuous audio input and cannot reliably respond to text-based control commands mid-conversation. **Recommendation:** If you need full call control support (`inject-context`, `say`, `transfer` with announcements), use the traditional pipeline: - **Provider**: `openai` with `gpt-4o` or `gpt-4o-mini` - **STT**: Deepgram (`nova-3-general`) - **TTS**: ElevenLabs or OpenAI TTS - **Result**: All control commands work reliably **Command Types:** - `inject-context`: Silently add information to the agent's context (traditional models only) - `say`: Make the agent speak specific text (traditional models only) - `end-call`: End the call with an optional final message (works with all models) - `transfer`: Transfer the call to another destination (partial xAI Realtime support) **Use Cases:** - SMS verification: Inject received codes into the conversation - CRM integration: Add customer context mid-call - Human escalation: Transfer to a live agent - Emergency end: Gracefully terminate problematic calls

List campaign leads GET

Retrieve all leads in a campaign.