POST
https://api.hyperleapai.com/conversations/personaStart a Conversation with a Persona.
Authenticated with your API key in the x-hl-api-key request header.
Request body
application/jsonpersonaIdstring · uuidrequiredpersonaVersionIdstring · uuidnullableobjectnullable
JsonNode
objectnullable
JsonNode
streambooleanexternalUserIdstringnullableResponses
200OK
application/jsonconversationIdstring · uuidaiSystemstringnullablemodelstringnullablepersonaIdstring · uuidnullablepersonaVersionIdstring · uuidnullableconversationStatusstringnullableconversationNamestringnullableHyperleapChatMessageResponse[]nullable
rolestringnullablecontentstringnullabletoolCallIdstringnullablenamestringnullablemessageIdstring · uuidtimestampstring · date-timeRunFeedback[]nullable
promptTokensinteger · int32completionTokensinteger · int32totalTokensinteger · int32read-onlyconversationRunIdstring · uuidread-onlychatMessagesCountinteger · int32nullablechatStartedbooleannullableareChatMessagesInBlobbooleannullablechatMessagesBlobUristringnullableobjectnullable
[key]anynullableobjectnullable
JsonNode
externalUserIdstringnullableisActivebooleanisDeletedbooleanpromptTokensinteger · int32nullablecompletionTokensinteger · int32nullabletotalTokensinteger · int32nullableExample payload
{
"conversationId": "string",
"aiSystem": "string",
"model": "string",
"personaId": "string",
"personaVersionId": "string",
"conversationStatus": "string",
"conversationName": "string",
"chatMessages": [
{
"role": "string",
"content": "string",
"toolCallId": "string",
"name": "string",
"messageId": "string",
"timestamp": "string",
"feedbacks": [
{
"comments": null,
"tags": null,
"scoreConfidence": null
}
],
"promptTokens": 0,
"completionTokens": 0,
"totalTokens": 0,
"conversationRunId": "string"
}
],
"chatMessagesCount": 0,
"chatStarted": true,
"areChatMessagesInBlob": true,
"chatMessagesBlobUri": "string",
"configuration": {
"key": "string"
},
"metadata": {
"key": {
"options": {
"propertyNameCaseInsensitive": true
}
}
},
"externalUserId": "string",
"isActive": true,
"isDeleted": true,
"promptTokens": 0,
"completionTokens": 0,
"totalTokens": 0
}{
"conversationId": "string",
"aiSystem": "string",
"model": "string",
"personaId": "string",
"personaVersionId": "string",
"conversationStatus": "string",
"conversationName": "string",
"chatMessages": [
{
"role": "string",
"content": "string",
"toolCallId": "string",
"name": "string",
"messageId": "string",
"timestamp": "string",
"feedbacks": [
{
"comments": null,
"tags": null,
"scoreConfidence": null
}
],
"promptTokens": 0,
"completionTokens": 0,
"totalTokens": 0,
"conversationRunId": "string"
}
],
"chatMessagesCount": 0,
"chatStarted": true,
"areChatMessagesInBlob": true,
"chatMessagesBlobUri": "string",
"configuration": {
"key": "string"
},
"metadata": {
"key": {
"options": {
"propertyNameCaseInsensitive": true
}
}
},
"externalUserId": "string",
"isActive": true,
"isDeleted": true,
"promptTokens": 0,
"completionTokens": 0,
"totalTokens": 0
}400Bad Request
application/jsonArray of ModelError
Exception
MethodBase
messageanytruncateddataanytruncatedinnerExceptionanytruncatedhelpLinkanytruncatedsourceanytruncatedhResultanytruncatedstackTraceanytruncatederrorMessageanytruncatedExample payload
[
{
"exception": {
"targetSite": {
"memberType": 1,
"name": "string",
"declaringType": {
"name": null,
"customAttributes": null,
"namespace": null,
"assemblyQualifiedName": null,
"fullName": null
}
}
}
}
][
{
"exception": {
"targetSite": {
"memberType": 1,
"name": "string",
"declaringType": {
"name": null,
"customAttributes": null,
"namespace": null,
"assemblyQualifiedName": null,
"fullName": null
}
}
}
}
]500Internal Server Error
No response body.
curl -X POST "https://api.hyperleapai.com/conversations/persona" \
-H "x-hl-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"personaId": "string",
"personaVersionId": "string",
"replacements": {
"key": {
"options": {
"propertyNameCaseInsensitive": true
}
}
},
"metadata": {
"key": {
"options": {
"propertyNameCaseInsensitive": true
}
}
},
"stream": true,
"externalUserId": "string"
}'curl -X POST "https://api.hyperleapai.com/conversations/persona" \
-H "x-hl-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"personaId": "string",
"personaVersionId": "string",
"replacements": {
"key": {
"options": {
"propertyNameCaseInsensitive": true
}
}
},
"metadata": {
"key": {
"options": {
"propertyNameCaseInsensitive": true
}
}
},
"stream": true,
"externalUserId": "string"
}'Example response · 200
{
"conversationId": "string",
"aiSystem": "string",
"model": "string",
"personaId": "string",
"personaVersionId": "string",
"conversationStatus": "string",
"conversationName": "string",
"chatMessages": [
{
"role": "string",
"content": "string",
"toolCallId": "string",
"name": "string",
"messageId": "string",
"timestamp": "string",
"feedbacks": [
{
"comments": null,
"tags": null,
"scoreConfidence": null
}
],
"promptTokens": 0,
"completionTokens": 0,
"totalTokens": 0,
"conversationRunId": "string"
}
],
"chatMessagesCount": 0,
"chatStarted": true,
"areChatMessagesInBlob": true,
"chatMessagesBlobUri": "string",
"configuration": {
"key": "string"
},
"metadata": {
"key": {
"options": {
"propertyNameCaseInsensitive": true
}
}
},
"externalUserId": "string",
"isActive": true,
"isDeleted": true,
"promptTokens": 0,
"completionTokens": 0,
"totalTokens": 0
}{
"conversationId": "string",
"aiSystem": "string",
"model": "string",
"personaId": "string",
"personaVersionId": "string",
"conversationStatus": "string",
"conversationName": "string",
"chatMessages": [
{
"role": "string",
"content": "string",
"toolCallId": "string",
"name": "string",
"messageId": "string",
"timestamp": "string",
"feedbacks": [
{
"comments": null,
"tags": null,
"scoreConfidence": null
}
],
"promptTokens": 0,
"completionTokens": 0,
"totalTokens": 0,
"conversationRunId": "string"
}
],
"chatMessagesCount": 0,
"chatStarted": true,
"areChatMessagesInBlob": true,
"chatMessagesBlobUri": "string",
"configuration": {
"key": "string"
},
"metadata": {
"key": {
"options": {
"propertyNameCaseInsensitive": true
}
}
},
"externalUserId": "string",
"isActive": true,
"isDeleted": true,
"promptTokens": 0,
"completionTokens": 0,
"totalTokens": 0
}