import { hubspot } from "@hubspot/ui-extensions";

/**
 * Chequea que exista el contacto
 * @param {string} cuit
 * @returns
 */
export const getHubspotInfo = async (cuit: string) => {
  const response = await hubspot.serverless("getContactsByCUIT", {
    parameters: {
      cuil: cuit,
    },
  });
  console.log("response in getHubspotInfo", response);
  return response.body;
};
