Replicas

Create a replica

Creates a new replica.

post/v1/replicas

Request

  • Base URL: https://api.sensay.io
  • URL: https://api.sensay.io/v1/replicas
  • Auth: API key in header X-ORGANIZATION-SECRET

Headers

X-API-Versionstring
Example:2025-03-25
Content-Encoding'gzip'

Content encoding for request body compression. Optional - when used, client is responsible for gzipping and sending binary data.

Request body

namestring required

The name of the replica.

purposestring

The purpose of the replica. This field is not used for training the replica.

shortDescriptionstring required

A short description of your replica. This field is not used for training the replica.

greetingstring required

The first thing your replica will say when you start a conversation with them.

type'individual' | 'character' | 'brand'

The replica type. individual: A replica of yourself. character: A replica of a character: can be anything you want. brand: A replica of a business persona or organization.

ownerIDstring required

The replica owner ID.

privateboolean

Visibility of the replica. When set to true, only the owner and users on the allowlist will be able to find the replica and chat with it.

whitelistEmailsstring[]

Emails of users who can use the replica when the replica is private.

slugstring required

The slug of the replica. Slugs can be used by API consumers to determine the URLs where replicas can be found.

tagsstring[]

The tags associated with the replica. Tags help categorize replicas and make them easier to find.

profileImagestring

The URL of the profile image of the replica. The image will be downloaded, optimized and stored on our servers, so the URL in the response will be different. Supported formats: image/jpeg, image/jpg, image/pjpeg, image/png, image/bmp, image/x-windows-bmp, image/x-bmp, image/x-bitmap, image/x-ms-bmp, image/webp, image/avif

suggestedQuestionsstring[]

Suggested questions when starting a conversation.

voicePreviewTextstring

Text that can be used to generate a voice preview.

isEveryConversationAccessibleBySupportboolean

Whether the replica conversations are accessible to customer support

Example request

{
  "name": "John Smith",
  "purpose": "Acts as my AI twin for answering questions about my creative work.",
  "shortDescription": "Accountant from Brooklyn who loves sports.",
  "greeting": "What would you like to know?",
  "ownerID": "a-user-id",
  "whitelistEmails": [
    "user@domain.example"
  ],
  "slug": "example-replica",
  "tags": [
    "male",
    "italian"
  ],
  "profileImage": "https://images.invalid/photo.jpeg",
  "suggestedQuestions": [
    "What is the meaning of life?"
  ],
  "llm": {
    "model": "gpt-4o",
    "systemMessage": "Concise, knowledgeable, empathetic and cheerful.",
    "tools": [
      "getTokenInfo"
    ],
    "embeddingModel": "multilingual-e5-large"
  },
  "voicePreviewText": "Hi, I'm your Sensay replica! How can I assist you today?",
  "isEveryConversationAccessibleBySupport": true
}

Response

The created replica

successboolean required

Indicates if the replica was created successfully

uuidstring uuid required

The replica UUID

Example response

{
  "success": true,
  "uuid": "654c2874-0b43-4d84-85fc-62ba866da1cb"
}

Changes

No recorded changes to this operation across all 1 revision of this API.