Catalog/trade-compounding-target

Calculators

Compounding target / trades API

Compounding: project final = start·(1+r)^n over n trades, or solve trades n = ln(target/start)/ln(1+r) to reach a goal at a per-trade return. Deterministic compounding math LLMs fumble. Answers 'how many trades to double at 2%','what will 1000 grow to at 2% over 50 trades','trades needed to hit my target'.

Price$0.01per request
MethodPOST
Route/v1/calc/trade-compounding-target
StatusLive
MIME typeapplication/json
Rate limit120/minute
CacheNo cache
calctradingcompoundinggrowthtargetgoalequity-curvereturns
API URLhttps://x402.hexl.dev/v1/calc/trade-compounding-target
Integration docs
Example request
{
  "startBalance": 1000,
  "returnPerTradePct": 2,
  "trades": 50
}
Example response
{
  "startBalance": 1000,
  "returnPerTradePct": 2,
  "trades": 50,
  "finalBalance": 2691.58802907,
  "totalReturnPct": 169.158803,
  "formula": "final = start · (1 + r)^n"
}
Input schema
{
  "type": "object",
  "required": [
    "startBalance",
    "returnPerTradePct"
  ],
  "properties": {
    "startBalance": {
      "type": "number",
      "examples": [
        1000
      ]
    },
    "targetBalance": {
      "type": "number",
      "description": "Goal balance — solves for trades needed.",
      "examples": [
        2000
      ]
    },
    "returnPerTradePct": {
      "type": "number",
      "examples": [
        2
      ]
    },
    "trades": {
      "type": "number",
      "description": "Number of trades — projects a final balance.",
      "examples": [
        50
      ]
    }
  }
}
Output schema
{
  "type": "object",
  "additionalProperties": true
}