GET
/
conversation
/
{conversation-id}
/
messages
/
{count-msg-to-get}

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

conversation-id
string
required

ID of the conversation

count-msg-to-get
integer
required

Number of messages to retrieve

Response

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