Developer API
Embed Astrilio calculators, access jurisdiction rules as JSON, or connect via our MCP server.
Embeddable Calculators
Embed any calculator on your website with a single iframe:
<iframe src="https://astrilio.com/embed/mortgage-payment" width="100%" height="600" frameborder="0" title="Mortgage Calculator by Astrilio" ></iframe>
Replace mortgage-payment with any of the 24 available calculator slugs.
Available Calculators
mortgage-paymentamortization-schedulerent-increasesecurity-depositprorated-rentaffordabilitycap-ratecash-flowland-transfer-taxcash-on-cashcmhc-pmidscrirrstr-revenuestr-vs-ltrdepreciationclosing-costrent-to-incomerental-price-estimatorrent-vs-buymoving-costgenerator-sizinginsulation-paybackheat-pump-vs-furnaceMCP Server
Astrilio exposes calculator tools via an MCP (Model Context Protocol) HTTP endpoint hosted in the Astrilio backend. AI agents β Claude, GPT-4, and any MCP-compatible host β can call Astrilio calculators server-side without embedding the math locally.
Endpoint
GET https://api.astrilio.com/mcp/v1/tools # list available tools POST https://api.astrilio.com/mcp/v1/tools/call # execute a tool
Example β list tools
curl https://api.astrilio.com/mcp/v1/tools
Example β call a tool
curl -X POST https://api.astrilio.com/mcp/v1/tools/call \
-H "Content-Type: application/json" \
-d '{
"name": "mortgage_payment",
"arguments": {
"purchase_price": 750000,
"down_payment": 150000,
"annual_rate_pct": 5.5,
"amort_years": 25
}
}'Available Tools
mortgage_paymentMonthly mortgage payment with Canadian semi-annual or US monthly compounding.
{
"purchase_price": number, // required β purchase price
"down_payment": number, // required β down payment amount
"annual_rate_pct": number, // required β e.g. 5.5 for 5.5%
"amort_years": integer, // required β 1β30
"country": string // optional β "CA" (default) or "US"
}cap_rateCapitalization rate, NOI, and gross rent multiplier for a rental property.
{
"purchase_price": number, // required
"monthly_rent": number, // required β gross monthly rent
"annual_expenses": number, // required β total operating expenses/yr
"vacancy_rate_pct": number // optional β default 5
}cash_flowMonthly and annual net cash flow after all operating expenses and mortgage.
{
"monthly_rent": number, // required
"monthly_mortgage": number, // required
"annual_property_tax": number, // required
"annual_insurance": number, // required
"annual_maintenance": number, // required
"vacancy_rate_pct": number, // optional β default 5
"monthly_pm_fee": number // optional β default 0
}land_transfer_taxLand transfer tax by Canadian province including Toronto municipal layer and first-time buyer rebates.
{
"purchase_price": number, // required
"province": string, // required β e.g. "ON", "BC", "AB"
"include_toronto": boolean, // optional β default false
"first_time_buyer": boolean // optional β default false
}rent_increase_checkCheck if a proposed rent increase is within the legal guideline for a Canadian province.
{
"current_rent": number, // required
"proposed_rent": number, // required
"province": string, // optional β default "ON"
"year": integer // optional β default 2025
}cmhc_premiumCMHC mortgage default insurance premium, rate tier, and monthly payment impact.
{
"purchase_price": number, // required β max $1,500,000
"down_payment": number // required β min 5%
}Response Format
// Success
{ "content": [{ "type": "text", "text": "Monthly payment: $3,204.12\n..." }] }
// Error
{ "content": [{ "type": "text", "text": "purchase_price must be > 0" }], "isError": true }Rate Limits
Tool calls are limited to 20 requests per minute per IP. The tools list endpoint is unrestricted. A 429 Too Many Requests response is returned when the limit is exceeded.
More Developer Tools
Looking for broader developer utilities? Check out devtoolzy.com β a free collection of developer tools from Cosyslabs, including formatters, encoders, diff checkers, and more.
Open Rules API
All 64 jurisdiction packs are available as static JSON at /api/rules/<country>/<region>.json. Rules include rent increase guidelines, deposit limits, transfer tax brackets, and more β all with primary-source links and lastVerified timestamps. Free, no auth required.