Discussing the article: "Introduction to MQL5 (Part 29): Mastering API and WebRequest Function in MQL5 (III)"

 

Check out the new article: Introduction to MQL5 (Part 29): Mastering API and WebRequest Function in MQL5 (III).

In this article, we continue mastering API and WebRequest in MQL5 by retrieving candlestick data from an external source. We focus on splitting the server response, cleaning the data, and extracting essential elements such as opening time and OHLC values for multiple daily candles, preparing the data for further analysis.

Greetings and welcome back to Part 29 of  the Introduction to MQL5 series! In the previous article, we covered the elements of a URL and discovered how to use MQL5's API to get the most recent prices from external platforms. Additionally, you learned how to read the JSON response and retrieve the precise information you require.

We will go one step further in this article by working on a more useful project. We will link to an external platform and obtain complete candlestick data, including the time, open, high, low, and close prices of multiple candles, rather than just the current price. In this article, we will also extract each different element from this data once we get it and store it in several arrays. For instance, we would save all open prices in one array, all high prices in another, and so on. Your understanding of managing structured JSON responses, processing arrays in MQL5, and effectively structuring incoming market data will all improve as a result of this project.

Author: Israel Pelumi Abioye