Skip to main content
POST
/
quantlib
/
solver
/
finance
/
convexity
Calculate Bond Convexity
curl --request POST \
  --url https://finceptbackend.share.zrok.io/quantlib/solver/finance/convexity \
  --header 'Content-Type: application/json' \
  --header 'X-API-Key: <api-key>' \
  --data '
{
  "face": 100,
  "coupon": 0.06,
  "maturity": 10,
  "ytm": 0.05,
  "frequency": 2
}
'
{
  "success": true,
  "data": {
    "convexity": 71.23
  }
}

Authorizations

X-API-Key
string
header
required

API key for authentication. Get your key at https://finceptbackend.share.zrok.io/auth/register

Body

application/json
coupon
number
required

Annual coupon rate as a decimal

Example:

0.06

maturity
number
required

Time to maturity in years

Example:

10

ytm
number
required

Yield to maturity as a decimal

Example:

0.05

face
number
default:100

Face value of the bond

Example:

100

frequency
enum<integer>
default:2

Coupon payment frequency per year

Available options:
1,
2,
4,
12
Example:

2

Response

Successful Response

success
boolean
Example:

true

data
object