{"uid":"cap_PJs3ZUVVtUGJx5URVSU5F","slug":"marketing-spend-unit-economics-calculator-fd00ed83","name":"Marketing Spend Unit Economics Calculator","description":"Per-channel unit economics from spend, conversions and revenue: CPC, CPM, CPA, CAC, ROAS, ROI, conversion rate, and LTV to CAC. Ranks channels and suggests a budget shift. Pure computation over your inputs.","url":"https://api.agentstools.dev/marketing/spend","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"csv":{"type":"string","description":"Raw CSV or TSV text with a header row, as an alternative to rows"},"rows":{"type":"array","items":{"type":"object"},"description":"Per-channel rows with spend and any of impressions/clicks/conversions/revenue/ltv/customers"}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.02","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.02/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.02","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.02","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_WsWQ9oRj5dIS1F_X-wpyZ","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.02","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Computes per-channel marketing unit economics (CPC, CPM, CPA, CAC, ROAS, ROI, conversion rate, LTV:CAC) from raw spend/conversion/revenue inputs, ranks channels, and suggests budget reallocation.","exampleAgentPrompt":"Calculate the unit economics for my three marketing channels — Google Ads ($15,000 spend, 320 conversions, $48,000 revenue), Meta ($9,000 spend, 180 conversions, $22,500 revenue), and TikTok ($4,000 spend, 60 conversions, $8,400 revenue) — and tell me which channel has the best ROAS and where I should shift budget.","exampleUseCases":[{"title":"Monthly channel performance review","prompt":"Here are last month's numbers — Google Ads: $20,000 spend, 500 conversions, $75,000 revenue; Facebook: $12,000 spend, 210 conversions, $31,500 revenue; email: $2,000 spend, 150 conversions, $27,000 revenue. Compute CPC, CAC, ROAS, and ROI for each channel and rank them by efficiency."},{"title":"Budget reallocation before Q4 campaign","prompt":"I'm planning Q4 and want to know where to put more budget. My channels are: paid search ($30,000 spend, 700 conversions, $105,000 revenue), Instagram ($18,000 spend, 300 conversions, $36,000 revenue), YouTube ($10,000 spend, 120 conversions, $19,200 revenue). Calculate ROAS, LTV to CAC, and tell me which channel deserves a bigger budget share."},{"title":"New channel viability check","prompt":"I just ran a pilot on three channels — LinkedIn ($5,000 spend, 40 conversions, $16,000 revenue), Pinterest ($3,000 spend, 55 conversions, $8,250 revenue), and Reddit ($2,500 spend, 30 conversions, $6,000 revenue). Calculate CPA, conversion rate, and ROAS for each and tell me which one makes the most sense to scale."}],"resultDescription":"Returns a structured breakdown per channel including CPC, CPM, CPA, CAC, ROAS, ROI, conversion rate, and LTV:CAC ratio, plus a ranked list of channels by efficiency and a specific budget reallocation recommendation based on the computed metrics.","failureModes":["Missing required fields (spend, conversions, or revenue) returns a validation error","Zero conversions causes division-by-zero for CPA/CAC metrics — endpoint may return null or error for those fields","Negative or zero spend values rejected as invalid input","Mismatched array lengths between channels, spend, and revenue arrays cause parsing errors","Extremely small spend or conversion values may produce nonsensical ratios"],"whenToPreferThis":"Choose this endpoint when you need pure, deterministic computation of marketing unit economics from raw numbers — no external data fetching, no model uncertainty. Ideal when you already have spend, conversion, and revenue data and want structured metrics plus a channel ranking and budget recommendation in a single call. Prefer this over manual spreadsheet calculations or general-purpose LLM math when consistency and structured output matter.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-14T18:52:48.164Z","isFirstParty":false}