GET
/
conversation
/
{conversationId}
/
messages
/
{count}

Example JS Code to Get Messages from a Conversation

const apiUrl = 'https://api.chatvolt.ai';
const apiKey = 'XXX';
const conversationId = 'XXX';
const countMsgToGet = 10;

const res = await fetch(
  `${apiUrl}/conversation/${conversationId}/messages/${countMsgToGet}`,
  {
    headers: {
      Authorization: `Bearer ${apiKey}`,
    },
  }
);

Authorizations

Authorization
string
headerrequired

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

Path Parameters

conversationId
string
required

ID of the conversation from which the messages will be retrieved.

count
integer
default: 2required

Number of most recent messages to be retrieved. If not specified, the default is 2.

Response

200 - application/json
status
string
isAiEnabled
boolean
userId
string
organizationId
string
messages
object[]