2.3.4 term_structure
Purpose
Query annualised risk-free rate for a given country and maturity date on the curve.
Parameters
country (string, required):
Three-letter ISO code representing the country.
Supported value can be obtained by referring to Inframetrics® Country Codes.date (date, required):
The date for the term structure.maturity_date (date, required):
The maturity date on the term structure for which we want to query the rate.
Example
response = await service.term_structure(
country="GBR",
date=datetime.date(2022, 12, 31),
maturity_date=datetime.date(2023, 12, 31)
)
#Sample Response
#{
# "data": {
# "results": [
# {
# "countryId": 826,
# "countryName": "GBR",
# "reportDate": "2023-09-28",
# "valueDate": "2022-12-31",
# "maturityDate": "2023-12-31",
# "value": 0.0387629694278233,
# "value3": 0.037286617588171,
# "version": "2024-06-14T11:07:51.818000"
# }
# ]
# },
# "metaData": [
# {
# "dataCount": 1
# }
# ]
#}
Please kindly ignore “value3” in the result - this may be removed in the future.