Forex Brokers With REST API
An API is a collection of specifications and protocols for creating and integrating application software. It's also known as a contract between an information provider and an information user that establishes the content necessary from the consumer (the call) and the content required by the producer (the answer). REST is an acronym that stands for representational state transfer. A REST API (also known as RESTful API) is a type of application programming interface (API or web API) that adheres to the REST architectural style and allows interaction with RESTful web services.
Today, we will look at some of the best forex brokers with REST API. But before that, we need to know some of the advantages and disadvantages of using REST API in forex trading.
Advantages of REST API
- Speed - REST APIs are associated with the fast fetching of information and execution of orders. This is very important in a market that is as volatile as the forex market.
- Automation - Traders can attach trading bots to their accounts to automate the execution of orders.
- Flexibility - Because data is not linked to resources or methods with REST API, people can customize their APIs as they see fit.
- Accuracy - REST API programs and bots have trades automatically with precision.
- Backtesting - REST API easily pulls historical information on orders and price movements making it easy to backtest trading strategies.
Disadvantages of REST API
- Security - Unlike other Web APIs, REST does not impose any security protocols. It is upon the forex broker to provide a layer of security protocols.
- Increased trading cost - Some forex brokers may charge customers to use their APIs.
With that, let us now look at some forex brokers with REST API. We will specifically look at the trading conditions offered by the brokers and the regulatory statuses of the brokers.
Forex.com
Forex.com offers REST API services that allow clients to access live streaming pricing, trade execution, sophisticated order types, and over 5,500 of the world's most traded market instruments. Traders can use their algorithms or systems to execute trades and orders by integrating EAs and other tools. This API is easily compatible since it can be coded against any network-accessible programming language such as Perl-script, C++, Python, or VB.NET. This allows clients with the technical know-how to code their own programs to integrate with Forex.com.
On Forex.com, clients can trade more than 5,500 tradeable assets. This includes CFDs on forex, indices, shares, commodities, precious metals, and cryptocurrencies. Clients from the United States should be aware that CFDs are not available due to regulations. As such, they can only access forex, gold and silver, and futures and futures options. The trading platforms available to use include MetaTrader 4, MetaTrader 5, and Forex.com Trader.
Further, Forex.com offers great pricing when trading. There are three main trading accounts with different spreads. The spreads on this broker site can fall as low as 1.0 pips for major currency pairs on the standard account.
The Commission account and the Direct Market Access (DMA) account both charge a commission. The Commission account features spreads starting from 0.2 pips and charges a commission of $5 per 100k traded. The DMA account charges different commissions depending on the trading volume of a client. For example, a trader with a trading volume of $0M – $100M per month would pay a commission of $60 per $1 million traded.
In terms of regulations, we see great oversight from multiple regulatory organizations. Forex.com’s activities are supervised by the FCA, the ASIC, the IIROC, the CYSEC, the CFTC and the NFA. This suggests that Forex.com is committed to following the law.
74-76% of retail investor accounts lose money when trading CFDs with this provider.
eToro
Customers of eToro can use the eToroX API to trade on the eToroX exchange utilizing a REST API solution. This enables algorithmic traders and programmers to automatically issue or cancel orders to buy/sell crypto assets and obtain account information. EToroX manages all orders in the market. Customer orders are saved in numerous persistent (permanent) storage locations and the matching engine. The matching engine compares buy/sell orders. If a match (a buy order price equal to or higher than the sell order price) is identified, the orders are matched and executed within the specified price window. On the eToro broker site, REST API provides numerous capabilities such as getting the balance, managing orders, withdrawing funds, depositing funds, and so on.
The variety of trading instruments on eToro includes CFDs on stocks, commodities, EFTs, forex, crypto, and indices. The broker also allows clients to trade real stocks and cryptocurrencies. These products are tradeable on the eToro platform built by eToro itself. eToro has no hidden fees and no commissions. The company reveals all charges that apply when trading on its website under fees. In terms of spreads, the company offers fair pricing starting from as low as 1.0 pips for major currency pairs.
eToro operates under the watchful eye of several organizations. These include the CySEC in Cyprus, the FCA in the UK, the ASIC in Australia and many others. This is one of the most heavily regulated brokers in the market today.
51% of retail investor accounts lose money when trading CFDs with this provider.
OANDA US
OANDA US is another broker that provides REST API to its clients. The API is simple to integrate into a client’s existing platform, offering over 25 years of historical data across multiple currency pairs, as well as data on commodities, indices, and precious metals. They have direct access to real-time Forex rates so they can be confident that the information is dependable. Access to historical pricing data goes all the way back to 2005. Further, clients can place, alter, and close orders, manage their account settings, and see their account/trading history using the REST API provided by OANDA.
Clients can also access MetaTrader 4 and TradingView trading platforms. These platforms allow clients to trade forex and cryptocurrencies (via the PAX exchange). The typical spreads on OANDA start from 1.0 pips on major currency pairs. There is no minimum deposit, and traders can deposit up to US$9,000. This accommodates traders of all kinds.
OANDA is regulated by numerous regulators in different countries including the US, UK and Australia. In the US it is regulated by the NFA under the NFA ID 0325821.
Forex trading involves significant risk of loss and is not suitable for all investors.
Saxo Bank
Saxo Bank offers several trading platforms, including SaxoTraderGO, and SaxoTraderPRO. Saxo Bank also allows clients to connect to their capital market infrastructure using their API. They can integrate easily through the company’s REST OpenAPs which uses SAML and OAuth to provide secure and simple development. Through this, clients can access their entire capital markets infrastructure, including instrument and client portfolio data, charts, quotations, order placement, lead sign-up, and event notifications.
Clients can trade over 70,000 assets that include forex, stocks, EFTs, bonds, crypto, and mutual funds among others. Saxo boasts of providing ultra-competitive spreads starting at 0.6 pips on major currency pairs.
In terms of regulation, Saxo Capital Markets is regulated by multiple institutions. These include the Financial Conduct Authority (FCA) in the UK, the Australian Securities and Investments Commission (ASIC) in Australia, and the Swiss Financial Market Supervisory Authority (FINMA) in Switzerland. Such strong regulations help win the trust of traders and investors at large.
FXCM
FXCM is also another broker that offers the REST API platform. FXCM Rest API allows clients to receive live streaming forex quotes and historical data, backtest their algorithms, and construct their trading robot. Any trader with the technical know-how can program their own trading bots and deploy them on their accounts. They can also deploy bots that are already built by trading robot providers.
Some of the trading instruments on this broker site include forex and CFDs on indices, shares, and commodities. Additionally, this broker provides a great lineup of trading platforms including Trading Station and MetaTrader 4. The spreads on this platform are competitive on currency pairs and CFDs. These spreads can go as low as 1.0 pips for major currency pairs.
FXCM is regulated by multiple reputable organizations from different jurisdictions. Notably, the broker under the regulation of the FCA, the FSCA, the CySEC, and the ASIC. The company also has over 20 years in the market which is an impressive achievement.
IG Markets
REST API integration is also supported by IG. On this broker, integration is accomplished by four common HTTP operations where you can retrieve a resource, replace a resource, create a resource, and remove a resource. Most importantly, traders can integrate trading bots from various sources or code their own if they have the technical know-how.
This API gives clients access to a wide variety of market instruments. IG has one of the deepest collections of market instruments totalling over 18,000 assets. Clients of this broker can trade CFDs on forex, indices, commodities, shares, cryptocurrencies, and more. As the REST API allows it to fetch historical data, it is easy to use different programs to backtest trading strategies.
On another note, IG provides clients with industry-standard platforms including MetaTrader 4, ProRealTime, L2 Dealer, and the ProgressiveWebApp. The spreads in IG are manageable and most Swiss traders would be able to afford to trade with this broker. The average spreads on IG can fall as low as 0.6 pips for some major currency pairs.
Finally, this broker is regulated by the FCA alongside other organizations including the FINMA, the ASIC, and the FSCA. Regulations are an important feature to look at when choosing a broker to invest with. A broker with multiple regulations from reputable organizations stands out from the rest.
Final thoughts
As we have seen, REST APIs are very versatile and can improve the trading experience of an investor. There are many brokers that understand this and allow their clients to integrate different programs with their market offerings and trading platform. It's vital to note that each broker's API requirements, documentation, and usage restrictions may differ. It is suggested that you visit their separate websites for more information and read their API documentation to understand the capability and limitations of each API.
Additionally, knowing that a broker offers REST API is simply not enough to select it as your choice for a trading partner. You still have to look at the regulations, trading conditions including fees, and the availability of market instruments. Considering these different features, you can pick the broker that best suits your needs.
Regulated Brokers
The table below contains links to 3rd party websites of our top partners from whom we receive compensation at no additional cost to you.