{
  "format": "delx/intent-card/v1",
  "id": "cost-per-success-api",
  "intent": "Cost Per Success for an agent workflow",
  "title": "Cost Per Success API for agents",
  "description": "Compute cost per successful delivery from total cost and success count — call when dividing total cost by successful deliveries. Use for SRE/ops math agents buy from broad utility catalogs: SLA, error budget, success rate, and health scores with zero upstream cost. Returns deterministic machine-readable JSON for $0.003 USDC via x402 on Base. Execution is first-party, local-only, stateless, and memory-only with no paid upstream, no input retention, and no claim of live chain tip, web search, or media generation. Results are advisory; the caller owns authorization and production controls.",
  "keywords": [
    "Cost Per Success API",
    "Cost Per Success for agents",
    "pay per result API",
    "x402 API",
    "no API key"
  ],
  "updated_at": "2026-08-06",
  "canonical_url": "https://commerce.delx.ai/intents/cost-per-success-api",
  "machine_url": "https://commerce.delx.ai/intents/cost-per-success-api.json",
  "recommendation": {
    "tool_name": "util_cost_per_success",
    "service_name": "Delx Cost Per Success",
    "method": "POST",
    "resource": "https://api.delx.ai/api/v1/x402/cost-per-success",
    "price_usdc": "0.003",
    "payment_protocols": [
      "x402",
      "mpp"
    ],
    "input_schema": {
      "type": "object",
      "properties": {
        "total_cost": {
          "description": "Total cost incurred in the window.",
          "type": "number"
        },
        "success_count": {
          "description": "Number of successful deliveries.",
          "type": "number"
        }
      },
      "required": [
        "total_cost",
        "success_count"
      ],
      "additionalProperties": true
    },
    "example_input": {
      "total_cost": 12.5,
      "success_count": 50
    },
    "example_output": {
      "schema": "delx/util-cost-per-success/v1",
      "total_cost": 12.5,
      "success_count": 50,
      "cost_per_success": 0.25
    },
    "agentcash": {
      "buy": "npx agentcash@latest fetch https://api.delx.ai/api/v1/x402/cost-per-success -m POST -H 'x-delx-source: intent-card-cost-per-success-api' --max-amount 0.003 -b '{\"total_cost\":12.5,\"success_count\":50}'",
      "max_amount_usdc": "0.003"
    }
  },
  "attribution": {
    "header": "x-delx-source",
    "value": "intent-card-cost-per-success-api"
  },
  "evidence": {
    "paid_openapi": "https://api.delx.ai/openapi.x402.json",
    "governed_portfolio": "https://api.delx.ai/x402-portfolio.json",
    "live_contract": "https://api.delx.ai/api/v1/x402/cost-per-success"
  }
}
