brego81 / IG_Trading_API_for_Matlab

A simple and intuitive Matlab library designed to interact with ig.com web API. This library allows you to download historical data, monitor multiple markets, manage your positions and submit real-time orders.
GNU General Public License v2.0
5 stars 3 forks source link

This script no longer works #1

Open damien-ls opened 4 years ago

damien-ls commented 4 years ago

Running the test script fails by hanging, it seems the API of IG has changed, and this is returned to the JSON parsing method:

<!DOCTYPE html><!--[if IE 7]><html class="ie7 nojs" lang=""> <![endif]--><!--[if IE 8]><html class="ie8 nojs" lang=""> <![endif]--><!--[if IE 9]><html class="ie9 nojs" lang=""> <![endif]--><html class="gtie9" lang=""><!--<![endif]--><head> <title>400</title> <meta charset="utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1; requiresActiveX=true"> <meta property="og:title" content="400 Bad request!"> <meta property="og:url" content="/error/400.html.var"> <meta itemprop="url" content="/error/400"> <meta property="og:description" content="Bad request!"> <meta property="og:image" content="/error/include/og_image.jpg"> <meta name="keywords" content=""> <meta name="locale" id="locale" content="en_GB"> <meta name="softid" id="softid" content="igcom"> <meta name="apple-itunes-app" content="app-id=469403477"> <link rel="stylesheet" href="/error/include/errorpage.css" type="text/css"> <script type="text/javascript"> analytics = { s_account: "adviggrouprollup", cq_page_name: "puredeal:err:(none):400 Bad request!", path: "" }; </script></head><body class="body"> <div class="error-page"> <div class="header"> <div class="fluid-width inner"> <p class="logo"> <a class="logo-link" href="/"> <span class="screenreader">Go to homepage</span> </a> </p> </div> </div> <div class="breadcrumb"> <ul class="fluid-width"> <li>400</li> </ul> </div> <div class="content"> <h2 class="error-page-heading">400 Bad request!</h2> <p> Your browser (or proxy) sent a request that this server could not understand. </p> <div class="error-page-button"> <a class="button button-green" href="/">Go to homepage</a> </div> </div> <div class="footer"> <div class="smallprint"> <p>Spread bets and CFDs are leveraged products. Spread betting and CFD trading may not be suitable for everyone and can result in losses that exceed your initial deposit, so please ensure that you fully understand the risks involved. CFDs provided by IG Markets Limited, spread betting provided by IG Index Limited.</p> <p>IG is a trading name of IG Markets Limited (a company registered in England and Wales, company number 04008957) and IG Index Limited (a company registered in England and Wales, company number 01190902). Registered address at Cannon Bridge House, 25 Dowgate Hill, London EC4R 2YA. Both IG Markets Limited (register number 195355) and IG Index Limited (register number 114059) are authorised and regulated by the Financial Conduct Authority. Excludes binary bets, where IG Index Limited is licensed and regulated by the Gambling Commission, reference number 2628. IG supports responsible gambling, for information and advice please visit <a href="http://www.gambleaware.co.uk">www.gambleaware.co.uk</a>.</p> <p>The information on this site is not directed at residents of the United States or any particular country outside the UK and is not intended for distribution to, or use by, any person in any country or jurisdiction where such distribution or use would be contrary to local law or regulation.&nbsp;</p> <p>Apple, the Apple logo, iPod, iPad, iPod touch, and iTunes are trademarks of Apple Inc, registered in the US and other countries. iPhone is a trademark of Apple Inc. App Store is a service mark of Apple Inc.<br /><br />Android is a trademark of Google Inc.</p> <p>The trademark BlackBerry<sup>&reg;</sup>&nbsp;is the property of Research In Motion Limited and is registered and/or used in the US and countries around the world.</p> <p>Windows is a registered trademark of Microsoft Corporation in the United States and other countries.</p> </div> </div></div><script> window.dlog = function () { var qs = window.location.href.split('?')[1]||''; if(qs.indexOf('debug')>-1) { if (this.console) { console.log(arguments); } } };</script><script type="text/javascript" src="//a.c-dn.net/c/etc/designs/onedomain/clientlibs_sitecatalyst.js"></script></body></html>

damien-ls commented 4 years ago

Fixed in https://github.com/damien-ls/IG_Trading_API_for_Matlab/commit/43715a3c77febb2afc8e59d57faf268ce5bdf4f5