Chatwoot/app/javascript/widget/api/endPoints.js

19 lines
335 B
JavaScript
Raw Normal View History

const sendMessage = content => ({
url: `/api/v1/widget/messages${window.location.search}`,
params: {
message: {
content,
},
},
});
const getConversation = ({ before }) => ({
url: `/api/v1/widget/messages${window.location.search}`,
params: { before },
});
export default {
sendMessage,
getConversation,
};