@memori.ai/memori-api-client
Version:
React library to integrate a Memori in your app or website
23 lines • 1.01 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
const apiFetcher_1 = require("../apiFetcher");
exports.default = (apiUrl) => ({
getUnansweredQuestions: async (sessionId) => (0, apiFetcher_1.apiFetcher)(`/UnansweredQuestions/${sessionId}`, {
method: 'GET',
apiUrl,
}),
getUnansweredQuestionsPaginated: async (sessionId, from, howMany) => (0, apiFetcher_1.apiFetcher)(`/UnansweredQuestions/${sessionId}/${from}/${howMany}`, {
method: 'GET',
apiUrl,
}),
postUnansweredQuestion: async (sessionId, unansweredQuestion) => (0, apiFetcher_1.apiFetcher)(`/UnansweredQuestion/${sessionId}`, {
method: 'POST',
apiUrl,
body: unansweredQuestion,
}),
deleteUnansweredQuestion: async (sessionId, unansweredQuestionId) => (0, apiFetcher_1.apiFetcher)(`/UnansweredQuestion/${sessionId}/${unansweredQuestionId}`, {
method: 'DELETE',
apiUrl,
}),
});
//# sourceMappingURL=unansweredQuestions.js.map