Skip to main content
POST
/
orgs
/
{org_id}
/
assistants
Create Assistant
curl --request POST \
  --url https://api.useinvent.com/orgs/{org_id}/assistants \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "config": {
    "language": "auto",
    "model": "<string>",
    "stt": {
      "model": "<string>"
    },
    "tts": {
      "model": "<string>",
      "voice_id": "<string>"
    },
    "conversation": {
      "thread_mode": "new",
      "enable_memories": true,
      "enable_transfer_to_human_tool": true,
      "welcome_banner": "<string>",
      "suggested_messages": [
        "<string>"
      ],
      "auto_intro_message": "<string>",
      "enable_end_conversation_tool": true,
      "enable_block_contact_tool": true,
      "enable_auto_resolve": true,
      "enable_auto_follow_ups": true,
      "enable_auto_csat": true,
      "enable_private_chats": true
    },
    "knowledge_scope": "all",
    "timezone": "<string>",
    "instructions": "<string>"
  },
  "enabled": true,
  "avatar_id": "<string>",
  "generate_secret_key": true
}
'
{
  "id": "<string>",
  "name": "<string>",
  "enabled": true,
  "deleted": true,
  "secret_key": "<string>",
  "avatar_url": "<string>",
  "config": {
    "language": "auto",
    "model": "<string>",
    "stt": {
      "model": "<string>"
    },
    "tts": {
      "model": "<string>",
      "voice_id": "<string>"
    },
    "conversation": {
      "thread_mode": "new",
      "enable_memories": true,
      "enable_transfer_to_human_tool": true,
      "welcome_banner": "<string>",
      "suggested_messages": [
        "<string>"
      ],
      "auto_intro_message": "<string>",
      "enable_end_conversation_tool": true,
      "enable_block_contact_tool": true,
      "enable_auto_resolve": true,
      "enable_auto_follow_ups": true,
      "enable_auto_csat": true,
      "enable_private_chats": true
    },
    "knowledge_scope": "all",
    "timezone": "<string>",
    "instructions": "<string>"
  },
  "integrations": [
    {
      "id": "<string>",
      "enabled": true,
      "integration_id": "internal",
      "assistant_id": "<string>",
      "connection_id": "<string>",
      "config": {},
      "error": "<string>",
      "created_at": "2023-11-07T05:31:56Z",
      "updated_at": "2023-11-07T05:31:56Z"
    }
  ],
  "actions": [
    {
      "id": "<string>",
      "enabled": true,
      "name": "<string>",
      "instructions": "<string>",
      "action_id": "<string>",
      "assistant_id": "<string>",
      "connection_id": "<string>",
      "config": {
        "input": {},
        "definitions": [
          {
            "path": "<string>",
            "definition": {}
          }
        ]
      },
      "created_at": "2023-11-07T05:31:56Z",
      "updated_at": "2023-11-07T05:31:56Z"
    }
  ],
  "created_at": "2023-11-07T05:31:56Z",
  "updated_at": "2023-11-07T05:31:56Z"
}

Path Parameters

org_id
string
required

The ID of the org

Body

The assistant information.

Schema for creating a new assistant

name
string
required

The name of the assistant

Required string length: 1 - 1024
config
object
required

Schema for the configuration of an assistant

enabled
boolean

Whether the assistant is enabled

avatar_id
string | null

The ID of the avatar file id

generate_secret_key
boolean

When true, generates a secret key immediately (same as POST …/rotate-secret-key). When omitted or false, no secret key is stored until you rotate.

Response

200 - application/json

The created assistant.

Schema for an assistant

id
string
required
name
string
required

The name of the assistant

enabled
boolean
required

Whether the assistant is enabled

deleted
boolean
required

Whether the assistant has been soft-deleted

secret_key
string | null
required

The secret key to create session hashes

avatar_url
string | null
required

The URL of the avatar photo

config
object
required

Schema for the configuration of an assistant

integrations
object[]
required
actions
object[]
required
created_at
string<date-time> | null
required
updated_at
string<date-time> | null
required