Black-Scholes option price and Greeks API
The Black-Scholes-Merton price of a European call or put with delta, gamma, vega, theta and rho, correct to the last digit shown.
POST https://api.curatedapi.com/v1/calc/finance/black-scholes
- Version 1
- MCP tool
calc_finance_black_scholes - Try it in the browser
Values a European option on a stock, index or currency with the Black-Scholes formula, with Merton's extension for a continuous dividend yield. The answer has the price and the five Greeks, and d1 and d2 for checking by hand. The normal distribution is evaluated with proven error bounds, so every digit returned is correct, including for options far in or out of the money where spreadsheet formulas lose digits.
Formula
call = S·e^(−qT)·Φ(d1) − K·e^(−rT)·Φ(d2); put = K·e^(−rT)·Φ(−d2) − S·e^(−qT)·Φ(−d1); d1 = (ln(S/K) + (r − q + σ²/2)·T) / (σ·√T), d2 = d1 − σ·√T
- The model is for European options, which can be exercised only at expiry. An American option is worth at least as much, and more when early exercise can pay.
- Rates are continuously compounded and per year, and time is in years. A rate quoted with annual compounding, R, is ln(1 + R) continuously compounded.
- vega and rho are the change for a move of one percentage point in volatility or the rate; theta is the change over one calendar day (the yearly figure divided by 365).
Inputs
Send numbers as strings to keep every digit. options sets precision and rounding (see numbers and rounding).
| Input | Type | Description |
|---|---|---|
spot required |
decimal (string) | The underlying's price now. A ratio of two decimals such as "0.08/12" is accepted. Allowed: > 0 and <= 1000000000000000. |
strike required |
decimal (string) | The option's strike price. A ratio of two decimals such as "0.08/12" is accepted. Allowed: > 0 and <= 1000000000000000. |
time_to_expiry_years required |
decimal (string) | Time to expiry in years. Write days as a ratio, such as "30/365". A ratio of two decimals such as "0.08/12" is accepted. Allowed: > 0 and <= 100. |
volatility_percent required |
decimal (string) | Volatility per year in percent (20 for 20%). Allowed: > 0 and <= 1000. Unit: percent. |
risk_free_rate_percent required |
decimal (string) | Risk-free interest rate per year in percent, continuously compounded. Allowed: >= -50 and <= 100. Unit: percent. |
dividend_yield_percent |
decimal (string) default 0 |
Dividend yield per year in percent, continuously compounded. Allowed: >= -50 and <= 100. Unit: percent. |
option_type required |
call | put | Call or put. Options: call: the right to buy; put: the right to sell |
options.rounding |
half_even | half_up | half_down | up | down | ceiling | floor | Rounding mode applied once to each result. Default half_even. |
options.decimals |
integer | Round results to this many digits after the decimal point. |
options.significant_digits |
integer | Round results to this many significant digits. |
Result
Under result in the answer, next to exactness, precision, inputs, formula, references and warnings.
| Result | Type | Description |
|---|---|---|
price | decimal (string) | The option's value. Unit: currency. |
delta | decimal (string) | Change in the price for a change of 1 in the underlying price. |
gamma | decimal (string) | Change in delta for a change of 1 in the underlying price. |
vega | decimal (string) | Change in the price for one percentage point more volatility. |
theta | decimal (string) | Change in the price over one calendar day, other things equal. |
rho | decimal (string) | Change in the price for one percentage point more interest. |
d1 | decimal (string) | The model's d1. |
d2 | decimal (string) | The model's d2. |
Examples
A six-month call: stock at 42, strike 40, 10% rate, 20% volatility
curl https://api.curatedapi.com/v1/calc/finance/black-scholes \
-H "Authorization: Bearer $CURATEDAPI_KEY" \
-H "Content-Type: application/json" \
-d '{
"spot": "42",
"strike": "40",
"time_to_expiry_years": "0.5",
"volatility_percent": "20",
"risk_free_rate_percent": "10",
"option_type": "call"
}'
{
"calculator": "finance/black-scholes@1",
"result": {
"price": "4.759422",
"delta": "0.779131",
"gamma": "0.049963",
"vega": "0.088134",
"theta": "-0.012491",
"rho": "0.139820",
"d1": "0.769263",
"d2": "0.627841"
},
"exactness": {
"price": "rounded",
"delta": "rounded",
"gamma": "rounded",
"vega": "rounded",
"theta": "rounded",
"rho": "rounded",
"d1": "rounded",
"d2": "rounded"
},
"precision": {
"rounding": "half_even",
"decimals": 6
},
"inputs": {
"spot": "42",
"strike": "40",
"time_to_expiry_years": "0.5",
"volatility_percent": "20",
"risk_free_rate_percent": "10",
"dividend_yield_percent": "0",
"option_type": "call"
},
"formula": "call = S·e^(−qT)·Φ(d1) − K·e^(−rT)·Φ(d2); put = K·e^(−rT)·Φ(−d2) − S·e^(−qT)·Φ(−d1); d1 = (ln(S/K) + (r − q + σ²/2)·T) / (σ·√T), d2 = d1 − σ·√T",
"references": [
{
"title": "The Nobel Prize in Economic Sciences 1997: Merton and Scholes, a new method to determine the value of derivatives",
"url": "https://www.nobelprize.org/prizes/economic-sciences/1997/press-release/"
}
],
"warnings": []
}
The put on the same terms
curl https://api.curatedapi.com/v1/calc/finance/black-scholes \
-H "Authorization: Bearer $CURATEDAPI_KEY" \
-H "Content-Type: application/json" \
-d '{
"spot": "42",
"strike": "40",
"time_to_expiry_years": "0.5",
"volatility_percent": "20",
"risk_free_rate_percent": "10",
"option_type": "put"
}'
{
"calculator": "finance/black-scholes@1",
"result": {
"price": "0.808599",
"delta": "-0.220869",
"gamma": "0.049963",
"vega": "0.088134",
"theta": "-0.002066",
"rho": "-0.050425",
"d1": "0.769263",
"d2": "0.627841"
},
"exactness": {
"price": "rounded",
"delta": "rounded",
"gamma": "rounded",
"vega": "rounded",
"theta": "rounded",
"rho": "rounded",
"d1": "rounded",
"d2": "rounded"
},
"precision": {
"rounding": "half_even",
"decimals": 6
},
"inputs": {
"spot": "42",
"strike": "40",
"time_to_expiry_years": "0.5",
"volatility_percent": "20",
"risk_free_rate_percent": "10",
"dividend_yield_percent": "0",
"option_type": "put"
},
"formula": "call = S·e^(−qT)·Φ(d1) − K·e^(−rT)·Φ(d2); put = K·e^(−rT)·Φ(−d2) − S·e^(−qT)·Φ(−d1); d1 = (ln(S/K) + (r − q + σ²/2)·T) / (σ·√T), d2 = d1 − σ·√T",
"references": [
{
"title": "The Nobel Prize in Economic Sciences 1997: Merton and Scholes, a new method to determine the value of derivatives",
"url": "https://www.nobelprize.org/prizes/economic-sciences/1997/press-release/"
}
],
"warnings": []
}
References
Results follow each calculator's documented rules and the sources listed. They are not financial, tax or legal advice. Check that the rules fit your case before you rely on a result. See the terms.
Errors share one format; see errors. Billing, retries and batches work the same for every endpoint.