POST
/
ai-assistants
cURL
curl --request POST \
  --url https://api.puretalk.ai/api/ai-assistants \
  --header 'Content-Type: application/json' \
  --header 'X-API-KEY: <api-key>' \
  --data '{
  "who_speaks_first": "assistant",
  "name": "<string>",
  "voice": 123,
  "prompt": "<string>",
  "model": "puretalk-plg",
  "begin_message": "<string>",
  "call_recording_enabled": true,
  "assistant_type": "single_prompt",
  "avatar": "<string>",
  "custom_knowledge_base": "<string>",
  "timezone": "<string>",
  "reminder_message_frequency": 123,
  "max_reminder_messages": 123,
  "voice_stability": "<string>",
  "voice_clarity_similarity": "<string>",
  "voice_stream_latency_optimization": 123,
  "voice_boost": false,
  "knowledge_base": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "template": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "behavior": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}'
{
  "msg": "<string>",
  "err": true,
  "results": {
    "assistant_id": "123e4567-e89b-12d3-a456-426614174000",
    "name": "My AI Assistant",
    "prompt": "Hello, how are you?",
    "model": "gpt-3.5-turbo",
    "who_speaks_first": "assistant",
    "begin_message": "Hello, how are you?",
    "assistant_type": "single_prompt",
    "avatar": "<string>",
    "custom_knowledge_base": "<string>",
    "timezone": "<string>",
    "voice_stability": 0.5,
    "voice_clarity_similarity": 0.5,
    "voice_stream_latency_optimization": 2,
    "voice_boost": false,
    "voice_speed": 0,
    "voice_emotion": [],
    "call_recording_enabled": true,
    "reminder_message_frequency": 1,
    "max_reminder_messages": 1,
    "post_analysis": "<string>",
    "chatbot_logo": "<string>",
    "chatbot_accent_color": "<string>",
    "chatbot_faq": "<string>",
    "chatbot_whitelisted_domains": [
      "<string>"
    ],
    "chatbot_begin_message": "<string>",
    "tools": "<string>",
    "created_at": "2023-11-07T05:31:56Z",
    "updated_at": "2023-11-07T05:31:56Z",
    "behavior": 1,
    "user": {
      "name": "<string>",
      "dp": "<string>",
      "email": "[email protected]"
    },
    "voice": {
      "voice_id": "<string>",
      "name": "<string>",
      "avatar": "<string>",
      "gender": "<string>",
      "demo_audio_url": "<string>",
      "is_cloned": true,
      "language": "<string>",
      "description": "<string>"
    }
  }
}

Authorizations

X-API-KEY
string
header
required

Authorization header containing API key. You can find your API key in the dashboard under 'API Keys'.

Body

application/json
name
string
required

The name of the AI Assistant

voice
integer
required

The voice id of the AI Assistant

prompt
string
required

The prompt of the AI Assistant

begin_message
string
required

The begin message of the AI Assistant

model
enum<string>
default:puretalk-plg

The model of the AI Assistant

Available options:
puretalk-plg
who_speaks_first
enum<string>
default:assistant

Who speaks first value of the AI Assistant

Available options:
assistant
call_recording_enabled
boolean
default:true

If call recording is enabled for the AI Assistant

assistant_type
enum<string>
default:single_prompt

The assistant type of the AI Assistant

Available options:
single_prompt,
multi_prompt
avatar
string<uri> | null

The avatar url of the AI Assistant

custom_knowledge_base
string

The custom knowledge base of the AI Assistant

timezone
string

The timezone of the AI Assistant

reminder_message_frequency
integer

The reminder message frequency of the AI Assistant

max_reminder_messages
integer

The maximum reminder messages of the AI Assistant

voice_stability
string

The voice stability of the AI Assistant

voice_clarity_similarity
string

The voice clarity similarity of the AI Assistant

voice_stream_latency_optimization
integer

The voice stream latency optimization of the AI Assistant

voice_boost
boolean
default:false

Indicates if voice boost is enabled for the AI Assistant

knowledge_base
string<uuid>

The knowledge base id of the AI Assistant

template
string<uuid>

The template id of the AI Assistant

behavior
string<uuid>

The behavior id of the AI Assistant

Response

AI Assistant created

msg
string
err
boolean
results
object