Files
bot/apps/viewer/src/features/results/queries/createResultQuery.ts
2023-03-15 08:35:16 +01:00

10 lines
299 B
TypeScript

import { Result } from '@typebot.io/schemas'
import { sendRequest } from '@typebot.io/lib'
export const createResultQuery = async (typebotId: string) => {
return sendRequest<{ result: Result; hasReachedLimit: boolean }>({
url: `/api/typebots/${typebotId}/results`,
method: 'POST',
})
}