Skip to main content

Treasury Prices


Implementation details​

Class names​

Model nameParameters classData class
TreasuryPricesTreasuryPricesQueryParamsTreasuryPricesData

Import Statement​

from openbb_core.provider.standard_models.treasury_prices import (
TreasuryPricesData,
TreasuryPricesQueryParams,
)

Parameters​

NameTypeDescriptionDefaultOptional
dateUnion[date, str]A specific date to get data for. Defaults to the last business day.NoneTrue
providerLiteral['government_us', 'tmx']The provider to use, by default None. If None, the priority list configured in the settings is used. Default priority: government_us, tmx.NoneTrue

Data​

NameTypeDescription
issuer_namestrName of the issuing entity.
cusipstrCUSIP of the security.
isinstrISIN of the security.
security_typestrThe type of Treasury security - i.e., Bill, Note, Bond, TIPS, FRN.
issue_datedateThe original issue date of the security.
maturity_datedateThe maturity date of the security.
call_datedateThe call date of the security.
bidfloatThe bid price of the security.
offerfloatThe offer price of the security.
eod_pricefloatThe end-of-day price of the security.
last_traded_datedateThe last trade date of the security.
total_tradesintTotal number of trades on the last traded date.
last_pricefloatThe last price of the security.
highest_pricefloatThe highest price for the bond on the last traded date.
lowest_pricefloatThe lowest price for the bond on the last traded date.
ratefloatThe annualized interest rate or coupon of the security.
ytmfloatYield to maturity (YTM) is the rate of return anticipated on a bond if it is held until the maturity date. It takes into account the current market price, par value, coupon rate and time to maturity. It is assumed that all coupons are reinvested at the same rate.