v1

latestOpenAPI 3.1.02026-07-13154170539.0 KB
Assistant Management

Create a contact detail for an assistant

Provisions external infrastructure (phone number, email, or WhatsApp sender) for the given assistant and creates a billing-tracked AssistantContact record. Deducts the one-time setup cost from credits.

post/v0/assistant/{assistant_id}/contact

Path parameters

assistant_idinteger required

Request body

contact_type'phone' | 'email' | 'whatsapp' required

The type of contact detail to create.

phone_countrystring nullable

Country code for phone number provisioning (e.g., 'US', 'GB'). Only used for phone contacts.

user_phonestring nullable

User's personal phone number (for forwarding). Only used for phone contacts.

email_localstring nullable

Local part of the email address (before @). Only used for email contacts.

first_namestring nullable

First name for Google Workspace account. Only used for email contacts.

last_namestring nullable

Last name for Google Workspace account. Only used for email contacts.

user_whatsapp_numberstring nullable

User's WhatsApp number to associate with the sender. Only used for WhatsApp contacts.

Example request

{
  "contact_type": "phone",
  "phone_country": "US",
  "user_phone": "+15551234567",
  "email_local": "ada.lovelace",
  "first_name": "Ada",
  "last_name": "Lovelace",
  "user_whatsapp_number": "+15551234567"
}

Response

Contact created successfully.

Example response

{
  "info": {
    "first_name": "Ada",
    "surname": "Lovelace",
    "age": 28,
    "weekly_limit": 15.75,
    "max_parallel": 2,
    "nationality": "North America",
    "profile_photo": "https://example.com/photos/ada.jpg",
    "profile_video": "https://example.com/videos/ada.mp4",
    "desktop_mode": "windows",
    "user_desktop_id": 1,
    "about": "Mathematician and writer known for work on Analytical Engine",
    "voice_id": "bf0a246a-8642-498a-9950-80c35e9276b5",
    "voice_provider": "elevenlabs",
    "pre_hire_chat": [
      {
        "role": "assistant",
        "msg": "Hello, how can I help you?"
      }
    ],
    "timezone": "America/New_York",
    "user_desktop_url": "https://abc123.tunnel.unify.ai",
    "user_desktop_mode": "macos",
    "agent_id": "12345",
    "user_id": "123",
    "created_at": "2025-04-25T10:30:00Z",
    "updated_at": "2025-04-26T14:15:00Z",
    "phone": "+15551234567",
    "phone_country": "US",
    "email": "ada.lovelace@unify.ai",
    "user_phone": "+15559876543",
    "user_whatsapp_number": "+15559876543",
    "assistant_whatsapp_number": "+15551234567",
    "api_key": "1234567890",
    "user_first_name": "Ada",
    "user_last_name": "Lovelace",
    "user_email": "ada.lovelace@unify.ai",
    "monthly_spending_cap": 100
  }
}