Build interactive yield curve charts for financial dashboards.
Financial analysts and investors need to visualize the Treasury yield curve to understand interest rate expectations and economic conditions.
Fetch all Treasury yields in a single API call and plot them by maturity. Compare current curves to historical dates to identify trends.
const res = await fetch("https://api.apiverve.com/v1/treasuryyields?date=2025-06&type=10yr", {
headers: { "x-api-key": "YOUR_API_KEY" },
});
const { data } = await res.json();
console.log(data);