# Marketing Spend Unit Economics Calculator

> Marketing Spend Unit Economics Calculator is a paid API for AI agents from api.agentstools.dev, paid per call via x402, $0.02/call, status unknown (last checked 2026-09-14).

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.

## Facts

- Endpoint: POST https://api.agentstools.dev/marketing/spend
- Price: $0.02/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/marketing-spend-unit-economics-calculator-fd00ed83
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_PJs3ZUVVtUGJx5URVSU5F

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability marketing-spend-unit-economics-calculator-fd00ed83 -d '<json body>'
```

Example prompt: 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.

## When to prefer this

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.

## Known failure modes

- 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

## How this service works

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.

## Output

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.

## Request schema (JSON Schema)

```json
{
 "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"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/marketing-spend-unit-economics-calculator-fd00ed83/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.agentstools.dev](https://www.zero.xyz/host/api.agentstools.dev/llms.txt)
