Mexico City Interbank Offered Rate 3-Month Historical Data API: Timeseries, Charts & Downloads

Mexico City Interbank Offered Rate 3-Month Historical Data API: Timeseries, Charts & Downloads

Introduction

In the fast-paced world of finance, accurate and timely interest rate data is crucial for developers, economists, and financial analysts. The Mexico City Interbank Offered Rate (RBA_CASH_RATE) is a key indicator that reflects the cost of borrowing between banks and serves as a benchmark for various financial products. Accessing historical data, analyzing trends, and visualizing this information can significantly enhance decision-making processes. This blog post will explore how to leverage the Interest Rates API to retrieve, analyze, and visualize the RBA_CASH_RATE data effectively.

Understanding the Importance of Interest Rate Data

Interest rates play a pivotal role in the economy, influencing everything from consumer loans to corporate financing. The RBA_CASH_RATE, specifically, is the rate at which banks lend to each other overnight, and it is a critical component in monetary policy. By utilizing the Interest Rates API, developers can access a wealth of data that can be used to build applications that forecast trends, assess risk, and optimize financial strategies.

API Overview

The Interest Rates API provides a comprehensive suite of endpoints designed to facilitate the retrieval of interest rate data. The API supports various operations, including fetching the latest rates, historical data, time series data, and more. Below, we will delve into the key endpoints relevant to the RBA_CASH_RATE and how to utilize them effectively.

Fetching Time Series Data

One of the most powerful features of the Interest Rates API is the ability to retrieve time series data using the /timeseries endpoint. This endpoint allows users to fetch a series of interest rates between two specified dates, making it ideal for analyzing trends over time.

Endpoint: /api/v1/timeseries

To retrieve time series data for the RBA_CASH_RATE, you will need to specify the start and end dates, as well as the symbol. Here’s how to make a request:

curl "https://interestratesapi.com/api/v1/timeseries?start=2025-09-01&end=2026-09-01&symbols=RBA_CASH_RATE&api_key=YOUR_KEY"

The expected JSON response will look like this:


{
"success": true,
"base": "USD",
"start_date": "2025-09-01",
"end_date": "2026-09-01",
"rates": {
"RBA_CASH_RATE": {
"2025-01-02": 5.33,
"2025-01-03": 5.33,
"2025-01-06": 5.33
}
},
"frequencies": {
"RBA_CASH_RATE": "daily"
},
"currencies": {
"RBA_CASH_RATE": "USD"
}
}

In this response, the rates object contains the RBA_CASH_RATE values for each date within the specified range. This data can be used for various analyses, such as calculating moving averages or identifying trends.

Implementation Example: Python Data Pipeline

To build a data pipeline that fetches the RBA_CASH_RATE time series data and exports it to a CSV file, you can use the following Python code:

import requests
import pandas as pd

# Define the API endpoint and parameters
url = 'https://interestratesapi.com/api/v1/timeseries'
params = {
'start': '2025-09-01',
'end': '2026-09-01',
'symbols': 'RBA_CASH_RATE',
'api_key': 'YOUR_KEY'
}

# Fetch the data
response = requests.get(url, params=params)
data = response.json()

# Extract rates into a DataFrame
rates = data['rates']['RBA_CASH_RATE']
df = pd.DataFrame(list(rates.items()), columns=['Date', 'RBA_CASH_RATE'])

# Export to CSV
df.to_csv('rba_cash_rate_timeseries.csv', index=False)

This code snippet demonstrates how to retrieve the time series data and convert it into a pandas DataFrame, which can then be easily exported to a CSV file for further analysis.

Point-in-Time Lookups with Historical Data

In addition to time series data, the Interest Rates API allows users to perform point-in-time lookups using the /historical endpoint. This is particularly useful for retrieving the RBA_CASH_RATE on specific dates, which can be critical for historical analysis.

Endpoint: /api/v1/historical

To fetch the RBA_CASH_RATE for a specific date, you can use the following request format:

curl "https://interestratesapi.com/api/v1/historical?date=2025-06-15&symbols=RBA_CASH_RATE&api_key=YOUR_KEY"

The expected JSON response will be:


{
"success": true,
"date": "2025-06-15",
"base": "USD",
"rates": {
"RBA_CASH_RATE": 5.33
},
"currencies": {
"RBA_CASH_RATE": "USD"
}
}

This response provides the RBA_CASH_RATE for the specified date, allowing for precise historical analysis.

Visualizing Data with OHLC Candlestick Charts

Visualizing interest rate data can provide valuable insights into trends and fluctuations. The /ohlc endpoint of the Interest Rates API allows users to retrieve Open-High-Low-Close (OHLC) data, which is essential for creating candlestick charts.

Endpoint: /api/v1/ohlc

To retrieve OHLC data for the RBA_CASH_RATE, you can use the following request:

curl "https://interestratesapi.com/api/v1/ohlc?symbols=RBA_CASH_RATE&period=monthly&start=2025-09-01&end=2026-09-01&api_key=YOUR_KEY"

The expected JSON response will look like this:


{
"success": true,
"period": "monthly",
"start_date": "2025-09-01",
"end_date": "2026-09-01",
"rates": {
"RBA_CASH_RATE": [
{
"period": "2025-01",
"open": 5.50,
"high": 5.50,
"low": 5.33,
"close": 5.33,
"data_points": 23
}
]
}
}

This response provides the OHLC data for the specified period, which can be used to create candlestick charts using libraries like Chart.js or Plotly. Below is an example of how to integrate this data into a Chart.js chart:


const ctx = document.getElementById('myChart').getContext('2d');
const chart = new Chart(ctx, {
type: 'candlestick',
data: {
datasets: [{
label: 'RBA Cash Rate',
data: [
{ x: '2025-01', o: 5.50, h: 5.50, l: 5.33, c: 5.33 }
]
}]
},
options: {
scales: {
x: {
type: 'time'
}
}
}
});

This code snippet demonstrates how to create a candlestick chart using Chart.js, providing a visual representation of the RBA_CASH_RATE data.

Analyzing Fluctuations in Interest Rates

Understanding fluctuations in interest rates is essential for risk management and financial forecasting. The /fluctuation endpoint allows users to analyze the change statistics over a specified date range.

Endpoint: /api/v1/fluctuation

To analyze fluctuations in the RBA_CASH_RATE, you can use the following request:

curl "https://interestratesapi.com/api/v1/fluctuation?start=2025-09-01&end=2026-09-01&symbols=RBA_CASH_RATE&api_key=YOUR_KEY"

The expected JSON response will be:


{
"success": true,
"rates": {
"RBA_CASH_RATE": {
"start_date": "2025-09-01",
"end_date": "2026-09-01",
"start_value": 5.50,
"end_value": 5.33,
"change": -0.17,
"change_pct": -3.09,
"high": 5.50,
"low": 5.25
}
}
}

This response provides valuable insights into the changes in the RBA_CASH_RATE over the specified period, including the percentage change and the highest and lowest values.

Conclusion

The Interest Rates API offers a robust set of tools for accessing and analyzing interest rate data, particularly the RBA_CASH_RATE. By leveraging the various endpoints, developers can build powerful applications that provide insights into financial trends, optimize decision-making, and enhance risk management strategies. Whether you are fetching time series data, performing historical lookups, visualizing trends, or analyzing fluctuations, the API provides the necessary resources to succeed in the competitive financial landscape.

For more information on how to get started, visit Get started with Interest Rates API and explore the features available to you.

Ready to get started?

Get your API key and start validating bank data in minutes.

Get API Key

Related posts