---
updatedAt: 2026-02-25T12:57:11.000Z
---

# KustomerCore.createConversation()

Creates a new session in Kustomer so you can start sending messages.

> 👍 First, initialize chat
>
> You must initialize with `KustomerCore.init()` before you can execute any additional Core SDK methods

## Examples

```javascript Code samples: KustomerCore.createConversation() 
KustomerCore.createConversation(
  {
    title: 'Conversation Title',
    assistant: 'SOME_ASSISTANT_ID',
    brand: 'SOME_BRAND_ID',
    lang: 'en',
  },
  (response, error) => {
    console.log('Session was created!');
  }
);
```

## Syntax

```javascript JavaScript syntax: KustomerCore.createConversation() 
KustomerCore.createConversation(options, function(callbackResponse, error))
```

[block:parameters]
{
  "data": {
    "h-0": "Parameter",
    "h-1": "Type",
    "h-2": "Description",
    "0-0": "options",
    "0-1": "Object",
    "0-2": "**Optional**  \n  \nThese are options that you can pass in to modify the created session. All possible options are listed below.",
    "1-0": "function(callbackResponse, error)",
    "1-1": "Function",
    "1-2": "**Optional**  \n  \nA callback that is run after `KustomerCore.createConversation()` completes.  \n  \n**callbackResponse** is an object returned to the callback function. See the `callbackResponse` section below to see the properties of the object.  \n  \n**error** is either `undefined` or a native JavaScript Error object."
  },
  "cols": 3,
  "rows": 2,
  "align": [
    "left",
    "left",
    "left"
  ]
}
[/block]

### `options`

[block:parameters]
{
  "data": {
    "h-0": "Property",
    "h-1": "Type",
    "h-2": "Description",
    "0-0": "title",
    "0-1": "String",
    "0-2": "**Required**  \n  \nThe title or subject line of the conversation. Limited to 256 characters.",
    "1-0": "brand",
    "1-1": "String",
    "1-2": "**Required**  \n  \nThe brand that the conversation belongs to.",
    "2-0": "assistant",
    "2-1": "String",
    "2-2": "**Optional**  \n  \nThe conversational assistant being used in the conversation.",
    "3-0": "lang",
    "3-1": "String",
    "3-2": "**Optional**  \n  \nThe lang code that the created conversation should be set to."
  },
  "cols": 3,
  "rows": 4,
  "align": [
    "left",
    "left",
    "left"
  ]
}
[/block]

### `callbackResponse`

[block:parameters]
{
  "data": {
    "h-0": "Property",
    "h-1": "Type",
    "h-2": "Description",
    "0-0": "conversationId",
    "0-1": "String",
    "0-2": "**Required**  \n  \nThe conversation unique ID",
    "1-0": "createdAt",
    "1-1": "String",
    "1-2": "**Required**  \n  \nThe conversation's created at timestamp",
    "2-0": "ended",
    "2-1": "Boolean",
    "2-2": "**Required**  \n  \nWhether or not the conversation is ended.",
    "3-0": "isInAssistantMode",
    "3-1": "Boolean",
    "3-2": "Whether or not the conversation is still in assistant mode."
  },
  "cols": 3,
  "rows": 4,
  "align": [
    "left",
    "left",
    "left"
  ]
}
[/block]