UNPKG

@memori.ai/memori-api-client

Version:

React library to integrate a Memori in your app or website

30 lines 1.18 kB
import { apiFetcher } from '../apiFetcher'; export default (apiUrl) => ({ getExpertReferences: async (sessionId) => apiFetcher(`/ExpertReferences/${sessionId}`, { method: 'GET', apiUrl, }), getExpertReferencesPaginated: async (sessionId, from, howMany) => apiFetcher(`/ExpertReferences/${sessionId}/${from}/${howMany}`, { method: 'GET', apiUrl, }), getExpertReference: async (sessionId, expertID) => apiFetcher(`/ExpertReference/${sessionId}/${expertID}`, { method: 'GET', apiUrl, }), updateExpertReference: async (sessionId, expertReference) => apiFetcher(`/ExpertReference/${sessionId}/${expertReference.expertID}`, { method: 'PATCH', apiUrl, body: expertReference, }), createExpertReference: async (sessionId, expertReference) => apiFetcher(`/ExpertReference/${sessionId}`, { method: 'POST', apiUrl, body: expertReference, }), deleteExpertReference: async (sessionId, expertID) => apiFetcher(`/ExpertReference/${sessionId}/${expertID}`, { method: 'DELETE', apiUrl, }), }); //# sourceMappingURL=expertReferences.js.map