For the complete documentation index, see llms.txt. This page is also available as Markdown.

Fetching Forward Swap Curves

Fetch forward-starting swap rates across multiple start dates in a single request, for scenario analysis and forward rate curve construction.

The /forward_swap_curve endpoint returns swap rates for a single tenor across multiple forward start dates in one request. Use this instead of making multiple /swap_rate calls when you need to see how a swap rate evolves across different start dates.


When to Use Forward Swap Curves

Use Case
Why a Forward Swap Curve?

Scenario analysis

See how the 5Y swap rate changes for swaps starting 3M, 6M, 1Y from now

Pre-hedging strategy

Compare rates for different hedge start dates to choose optimal timing

Curve visualisation

Build forward swap rate charts for presentations or dashboards

Batch pricing

Price multiple forward-starting swaps without hitting rate limits

vs. /swap_rate: The /swap_rate endpoint prices one swap at a time. This endpoint returns an entire curve in a single call, which is faster and avoids rate limits.


Basic Example

Get 5Y SOFR swap rates for forward starts every 3 months over the next 2 years:

import requests

url = "https://api.bluegamma.io/v1/forward_swap_curve"
headers = {"x-api-key": "your_api_key"}

params = {
    "index": "SOFR",
    "tenor": "5Y",
    "end_date": "2Y",
    "frequency": "3M",
    "fixed_leg_frequency": "12M"
}

response = requests.get(url, headers=headers, params=params)
data = response.json()

for point in data["curve"]:
    print(f"{point['start_date']} -> {point['maturity_date']}: {point['swap_rate']:.4f}%")

Response (April 2026):

Field
Description

curve

Array of forward-starting swap rate points

start_date

The forward start date for each swap

maturity_date

The maturity date (start_date + tenor)

swap_rate

The fair fixed rate for the swap as a percentage

tenor

The swap maturity length applied to each start date

frequency

The spacing between forward start dates

The curve shows the 5Y SOFR swap rate rising from 3.59% (spot) to 3.73% for a swap starting in 2 years, reflecting the upward-sloping rate environment.


Visualising the Curve

5Y SOFR forward swap curve showing rates rising from 3.59% to 3.73%
5Y SOFR forward swap curve - live API data, April 2026

Use Case: Comparing Tenors

Fetch forward swap curves for multiple tenors to see how the term structure evolves:


Parameters

Parameter
Required
Description

index

Yes

Interest rate index (e.g., SOFR, SONIA, 6M EURIBOR)

tenor

Yes

Swap maturity length (e.g., 5Y, 10Y). Applied from each start date

end_date

Yes

Last forward start date. Tenor like 2Y or date like 2028-04-16

frequency

Yes

Spacing between start dates (e.g., 1M, 3M, 6M, 1Y)

fixed_leg_frequency

Yes

Fixed leg payment frequency (e.g., 6M, 12M)

start_date

No

First forward start date. Defaults to spot if omitted

floating_leg_frequency

No

Floating leg payment frequency

fixed_leg_day_count

No

Day count convention for fixed leg (e.g., Actual360)

floating_leg_day_count

No

Day count convention for floating leg

valuation_time

No

Historical timestamp (ISO 8601) for reproducibility

is_end_of_month

No

Align dates to month-end (default: true)


If you need...
Use

A single forward-starting swap rate

/swap_rate

The full spot swap curve (all tenors)

/get_swap_curve

Forward interest rates (not swap rates)

/forward_curve

Historical swap rates over time

/historical_swap_rates


Need an API key? 📩 support@bluegamma.io | 📅 Book a call

Last updated

Was this helpful?