export type CreateApiBytemineV1AppsRoiCalculatorArgs = {body: {target_domain: string, your_domain?: string | undefined, your_product_description?: string | undefined, investment_amount?: string | undefined, contact_email?: string | undefined, contact_linkedin?: string | undefined, contact_name?: string | undefined, cta_link?: string | undefined}}; export type CreateApiBytemineV1AppsRoiCalculatorOptions = {baseUrl?: string | undefined, fetch?: typeof fetch | undefined}; /** * Generate a personalized ROI projection and business case with quantified savings, implementation timeline, risk analysis, and outreach copy. Returns a public shareable URL. 10 credits. * * POST /bytemine/v1/apps/roi-calculator */ export const createApiBytemineV1AppsRoiCalculator = async (args: CreateApiBytemineV1AppsRoiCalculatorArgs, options?: CreateApiBytemineV1AppsRoiCalculatorOptions) => { const {baseUrl = "https://api.orthogonal.com/mpp", fetch: fetchFn = fetch} = options ?? {} const query = new URLSearchParams() const headers = new Headers() headers.set('content-type', "application/json") const url = `${baseUrl.replace(/\/+$/, '')}/bytemine/v1/apps/roi-calculator${query.size > 0 ? `?${query}` : ''}` const res = await fetchFn(url, {method: "POST", headers, body: JSON.stringify(args.body)}) if (!res.ok) throw new Error(`Request failed with status ${res.status}`, {cause: {status: res.status, body: await res.text()}}) return undefined };