class RubyConversations::Client

def store_message(conversation, message)

Returns:
  • (Hash) - The API response data

Parameters:
  • message (Message) -- The message to store
  • conversation (Conversation) -- The conversation to add the message to
def store_message(conversation, message)
  response = client.post("api/ai_conversations/#{conversation.id}/ai_messages",
                         { ai_message: message.attributes_for_api })
  handle_response(response)
end