Bond Calc
bond_calcFixed-coupon bond math: price from yield or yield to maturity from price (clean and dirty, with accrued interest for fractional periods), current yield, Macaulay and modified duration, convexity and DV01, plus the cash-flow schedule. Treasury, corporate or zero-coupon bonds; any coupon frequency. Price: $0.002 USDC per successful call (x402, Solana). Same tool over HTTPS: GET https://scorptech.it.com/api/x402/v1/bond-calc
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"couponRatePct": "<couponRatePct>",
"yearsToMaturity": "<yearsToMaturity>"
},
"name": "bond_calc"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| price | No | Clean price (same units as faceValue): compute yield | |
| ytmPct | No | Yield to maturity in percent: compute price | |
| faceValue | No | ||
| frequency | No | Coupons per year | |
| couponRatePct | Yes | Annual coupon rate in percent (0 = zero-coupon) | |
| yearsToMaturity | Yes |