POST
/
v1
/
personas
curl --request POST \
  --url https://api.anam.ai/v1/personas \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "name": "Eva",
  "description": "Eva is the virtual receptionist of the fictional Sunset Hotel.",
  "personaPreset": "eva",
  "brainType": {},
  "brain": {
    "systemPrompt": "You are role-playing as a text chatbot hotel receptionist at The Sunset Hotel. Your name is Eva. Start with '\''Hi,\n    this is The Sunset Hotel reception, how may I help you?'\'' Be mindful of the hotel'\''s availability: single and double rooms\n    are still available all next week, except Tuesday. Dogs are allowed. There'\''s a restaurant and bar in the lobby. If\n    communication breaks down, ask if they want to speak to a human. Finish every response with a question to drive the\n     conversation. Do not repeat yourself.",
    "personality": "You are role-playing as a text chatbot hotel receptionist at The Sunset Hotel. Your name is Eva.",
    "fillerPhrases": [
      "Okay, got it.",
      "I see.",
      "Let me check that for you."
    ],
    "languageModel": "<string>"
  }
}'
{
  "id": "<string>",
  "name": "<string>",
  "description": "<string>",
  "personaPreset": "<string>",
  "brainType": {},
  "brain": {
    "systemPrompt": "You are role-playing as a text chatbot hotel receptionist at The Sunset Hotel. Your name is Eva. Start with 'Hi,\n    this is The Sunset Hotel reception, how may I help you?' Be mindful of the hotel's availability: single and double rooms\n    are still available all next week, except Tuesday. Dogs are allowed. There's a restaurant and bar in the lobby. If\n    communication breaks down, ask if they want to speak to a human. Finish every response with a question to drive the\n     conversation. Do not repeat yourself.",
    "personality": "You are role-playing as a text chatbot hotel receptionist at The Sunset Hotel. Your name is Eva.",
    "fillerPhrases": [
      "Okay, got it.",
      "I see.",
      "Let me check that for you."
    ],
    "languageModel": "<string>"
  },
  "isDefaultPersona": true,
  "createdAt": "2023-11-07T05:31:56Z",
  "updatedAt": "2023-11-07T05:31:56Z",
  "shareLinks": [
    {
      "id": "<string>",
      "token": "<string>",
      "usageLimit": 123,
      "expiresAt": "2023-11-07T05:31:56Z",
      "usageCount": 123
    }
  ]
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
name
string
required

The name for the persona

Example:

"Eva"

personaPreset
string
required

The persona preset defines the face and voice of the persona from our list of available presets. Currently, the only available preset is "eva".

Example:

"eva"

brainType
object
required

The type of brain to use for the persona.

brain
object
required

The brain configuration for the persona.

description
string

The description for the persona. This is an optional descriptor and is not used as part of the LLM prompt generation.

Example:

"Eva is the virtual receptionist of the fictional Sunset Hotel."

Response

201
application/json
id
string
required
name
string
required
personaPreset
string
required
brainType
object
required
brain
object
required
isDefaultPersona
boolean
required
createdAt
string
required
updatedAt
string | null
required
description
string