The Scenario
A client presentation is in 48 hours. It needs a yield curve chart — the full UST curve from 1 month to 30 years — for each of the past 24 months, overlaid so the audience can see how the shape has shifted. The data needs to be in a Google Sheet so the portfolio analyst can build the chart there and export it as an image. The EODHD API has the data. The analyst has neither the time nor the inclination to build the pull by hand.
The bad version:
- Read through the EODHD fixed-income endpoint documentation to figure out which endpoint returns UST par yields and which returns constant-maturity yields — they're different and the column headers don't make it obvious.
- Build a request loop: one call per maturity per month, 12 maturities, 24 months — that's 288 API calls, each returning a time series that needs to be filtered to the correct month-end date and placed in the right row and column.
- Import the assembled output, then notice that the 30-year maturity has a gap for one month in 2023 when the Treasury briefly stopped issuing 30Y bonds, which breaks the chart unless you handle it explicitly.
None of this is the analysis. The analysis is the 10 minutes you spend looking at the finished chart.
The Easy Way: One Prompt in SheetXAI
SheetXAI is an AI agent that lives inside your Google Sheet. It calls the EODHD treasury yield endpoints, assembles the curve across all maturities and months, and writes the matrix in the layout the chart needs — without the request loop or the response reshaping.
Pull US Treasury yield curve data for all maturities (1M through 30Y) for the past 2 years from EODHD and write date in column A, then one column per maturity in my 'Yield Curve' sheet.
What You Get
- Column A: month-end dates for the past 24 months
- One column per maturity from 1M to 30Y, with maturity labels in row 1
- Any month/maturity combination with missing data left blank, with a note identifying the gap
- Data in percentage format, ready to be used as chart source data without reformatting
What If the Data Is Not Quite Ready
You need daily data, not monthly end-of-period
The duration model runs on daily yield observations, not month-end snapshots.
Fetch daily UST par yields from EODHD for the 1Y, 2Y, 5Y, 10Y, and 30Y maturities for the past 24 months and fill my 'Treasury Rates' sheet with dates in column A and one column per maturity.
The sheet already has a partial year of yield data you want to extend
Someone started populating the sheet manually through September 2024. You need EODHD to pick up from October 2024 forward without overwriting what's already there.
In my 'Yield Curve' sheet, find the last date already populated in column A. Fetch UST yield curve data from EODHD starting the day after that date through today for all maturities and append the rows below the existing data.
The client wants spreads against the 2Y, not absolute yields
The presentation will show the 5Y-2Y, 10Y-2Y, and 30Y-2Y spreads over the period, not raw yields.
Pull UST yields for all standard maturities for the past 24 months from EODHD into my 'Yield Curve' sheet, then build a second tab called 'Spreads' showing the 5Y-2Y, 10Y-2Y, and 30Y-2Y spreads in basis points for each date.
Full presentation deck prep: raw yields + spreads + recession shade + summary stats
Pull 24 months of daily UST yields for the 2Y, 5Y, 10Y, and 30Y maturities from EODHD into my 'Yield Curve' sheet. Add a 'Spreads' tab with the 10Y-2Y inversion metric. Add a column flagging any date where the 10Y-2Y was negative. Add a 'Summary' tab with the current curve, the 12-month-ago curve, and the min/max spread for each maturity pair.
One prompt. Everything the analyst needs to finish the deck.
Try It
Get the 7-day free trial of SheetXAI and open any Google Sheet where you're building a fixed-income model, then ask it to fetch the Treasury curve from EODHD. You can also ask it to compare mutual fund fundamentals or see the full range of EODHD tasks at the integration hub.
