cal.pub0.org/packages/features/bookings/lib/create-booking.ts

9 lines
300 B
TypeScript

import { post } from "@calcom/lib/fetch-wrapper";
import type { BookingCreateBody, BookingResponse } from "../types";
export const createBooking = async (data: BookingCreateBody) => {
const response = await post<BookingCreateBody, BookingResponse>("/api/book/event", data);
return response;
};