{"openapi":"3.1.0","info":{"title":"FX Carry Trade API","version":"1.0.0","description":"Live carry-trade and rollover analytics that FX traders run before borrowing a low-yield currency to buy a high-yield one, computed on demand from the interest rates you pass in — no key, no cache, nothing stored. The carry endpoint returns the interest-rate differential, the carry income over a holding period, the financing-adjusted yield and the leveraged return on margin, so you see exactly what a position earns. The rollover endpoint returns the daily, weekly and monthly swap — positive when you receive carry, negative when you pay it — the number a broker debits or credits each night. The breakeven endpoint returns how far the spot rate can move against the position before the carry is wiped out: the cushion the carry buys you, and the break-even spot level. This is an interest-rate and carry engine, distinct from pip and lot calculators and price tools: it turns two yields, leverage and time into the income and the risk cushion of a carry trade. The carry trade is one of the most-used FX strategies (think funding in yen to hold a higher-yielding currency), and these are the numbers behind it. Computed locally and deterministically, so it is instant and private. Ideal for FX dashboards, strategy back-tests, position sizers and trading tools. Rates are annual percentages (5.5 = 5.5%). Live, nothing stored. 3 compute endpoints. For live policy rates feed them in from a central-bank or rates API.","contact":{"name":"PremiumApi","url":"https://www.oanor.com/by/premiumapi"}},"servers":[{"url":"https://api.oanor.com/carrytrade-api","description":"oanor gateway"}],"tags":[{"name":"Carry"},{"name":"Meta"}],"components":{"securitySchemes":{"oanorKey":{"type":"apiKey","in":"header","name":"x-oanor-key","description":"Get your key at https://www.oanor.com/developer/keys"}}},"security":[{"oanorKey":[]}],"paths":{"/v1/breakeven":{"get":{"operationId":"get_v1_breakeven","tags":["Carry"],"summary":"Adverse spot move the carry cushions","description":"","parameters":[{"name":"rate_long","in":"query","required":true,"description":"Annual yield of the bought currency (%)","schema":{"type":"string"},"example":"5.5"},{"name":"rate_short","in":"query","required":true,"description":"Annual yield of the funding currency (%)","schema":{"type":"string"},"example":"0.5"},{"name":"days","in":"query","required":false,"description":"Holding days (default 365)","schema":{"type":"string"},"example":"365"},{"name":"spot","in":"query","required":false,"description":"Spot rate for break-even level","schema":{"type":"string"},"example":"150"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"days":365,"spot":150,"source":"CARRY","breakeven_spot":142.5,"interpretation":"positive carry: the spot can move 5% against the long currency over 365 days before the trade nets a loss","differential_pct":5,"carry_yield_period_pct":5,"breakeven_adverse_move_pct":5},"meta":{"timestamp":"2026-06-11T07:49:22.504Z","request_id":"b70e4a84-d45e-4e38-8322-16aaa4b47885"},"status":"ok","message":"Breakeven computed","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/carry":{"get":{"operationId":"get_v1_carry","tags":["Carry"],"summary":"Differential, carry income & leveraged return","description":"","parameters":[{"name":"rate_long","in":"query","required":true,"description":"Annual yield of the bought currency (%)","schema":{"type":"string"},"example":"5.5"},{"name":"rate_short","in":"query","required":true,"description":"Annual yield of the funding currency (%)","schema":{"type":"string"},"example":"0.5"},{"name":"notional","in":"query","required":false,"description":"Position notional (default 100000)","schema":{"type":"string"},"example":"100000"},{"name":"leverage","in":"query","required":false,"description":"Leverage (default 1)","schema":{"type":"string"},"example":"10"},{"name":"days","in":"query","required":false,"description":"Holding days (default 365)","schema":{"type":"string"},"example":"365"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"days":365,"note":"differential = rate_long - rate_short - financing_spread (annual %). Positive carry earns; negative pays. Returns leveraged by margin = notional / leverage.","margin":10000,"source":"CARRY","leverage":10,"notional":100000,"direction":"positive_carry","rate_long":5.5,"rate_short":0.5,"daily_carry":13.69863,"differential_pct":5,"financing_spread":0,"carry_income_annual":5000,"carry_income_period":5000,"return_on_margin_annual_pct":50,"return_on_margin_period_pct":50},"meta":{"timestamp":"2026-06-11T07:49:22.593Z","request_id":"3f453786-03a0-48b7-a04a-d6f5e911719f"},"status":"ok","message":"Carry computed","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/rollover":{"get":{"operationId":"get_v1_rollover","tags":["Carry"],"summary":"Daily/weekly/monthly swap","description":"","parameters":[{"name":"rate_long","in":"query","required":true,"description":"Annual yield of the bought currency (%)","schema":{"type":"string"},"example":"5.5"},{"name":"rate_short","in":"query","required":true,"description":"Annual yield of the funding currency (%)","schema":{"type":"string"},"example":"0.5"},{"name":"notional","in":"query","required":false,"description":"Position notional (default 100000)","schema":{"type":"string"},"example":"100000"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"days":365,"note":"Swap/rollover is the carry accrued per day = notional x differential / 365. Positive = you receive it, negative = you pay it.","source":"CARRY","leverage":1,"notional":100000,"direction":"receive","daily_carry":13.69863,"period_carry":5000,"weekly_carry":95.890411,"monthly_carry":410.958904,"differential_pct":5,"daily_carry_pct_of_margin":0.01369863},"meta":{"timestamp":"2026-06-11T07:49:22.697Z","request_id":"14aeaeb0-3d2c-4356-ad24-71209c3edb70"},"status":"ok","message":"Rollover computed","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/meta":{"get":{"operationId":"get_v1_meta","tags":["Meta"],"summary":"Spec","description":"","parameters":[],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"note":"rate_long = yield of the bought currency, rate_short = yield of the funding currency, both annual % (5.5 = 5.5%). notional, leverage, days and financing_spread optional.","source":"Computed in-process from caller-supplied interest rates (no upstream)","service":"carrytrade-api","endpoints":{"GET /v1/meta":"This document.","GET /v1/carry":"Differential, carry income & leveraged return (rate_long=5.5&rate_short=0.5&notional=100000&leverage=10).","GET /v1/rollover":"Daily/weekly/monthly swap (rate_long=5.5&rate_short=0.5&notional=100000).","GET /v1/breakeven":"Adverse spot move the carry cushions (rate_long=5.5&rate_short=0.5&days=365&spot=150)."},"description":"Live carry-trade and rollover analytics computed on demand from two interest rates. The carry endpoint returns the interest-rate differential, the carry income over a period, the financing-adjusted yield and the leveraged return on margin; the rollover endpoint returns the daily/weekly/monthly swap (positive when you earn carry, negative when you pay); the breakeven endpoint returns how far the spot can move against the position before the carry is wiped out. An interest-rate / carry engine, distinct from pip/lot calculators and price tools. Computed locally, nothing stored.","upstream_status":"ok"},"meta":{"timestamp":"2026-06-11T07:49:22.794Z","request_id":"87fbf2af-90a1-4158-885b-0605efc986e2"},"status":"ok","message":"Meta","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}}},"x-oanor-pricing":[{"slug":"free","name":"Free","price_cents_month":0,"monthly_call_quota":4600,"rps_limit":2,"hard_limit":true},{"slug":"starter","name":"Starter","price_cents_month":770,"monthly_call_quota":90000,"rps_limit":6,"hard_limit":true},{"slug":"pro","name":"Pro","price_cents_month":2240,"monthly_call_quota":470000,"rps_limit":18,"hard_limit":true},{"slug":"business","name":"Business","price_cents_month":5200,"monthly_call_quota":2900000,"rps_limit":45,"hard_limit":true}],"x-oanor-marketplace-url":"https://www.oanor.com/api/carrytrade-api"}