Skip to main content
POST
/
v4
/
conversations
Ingest or update conversation
const options = {
  method: 'POST',
  headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
  body: JSON.stringify({
    conversationId: '<string>',
    messages: [
      {
        role: 'user',
        content: '<string>',
        name: '<string>',
        tool_calls: ['<unknown>'],
        tool_call_id: '<string>'
      }
    ]
  })
};

fetch('https://api.supermemory.ai/v4/conversations', options)
  .then(res => res.json())
  .then(res => console.log(res))
  .catch(err => console.error(err));

Authorizations

Authorization
string
header
required

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

Body

application/json
conversationId
string
required
Required string length: 1 - 255
messages
object[]
required
Minimum array length: 1
containerTags
string[]
metadata
object

Response

Conversation ingested/updated successfully