Jump to content
Sign in to follow this  
Guest mrdavidlaing

PriceHistory - Close <> Open

Recommended Posts

Guest mrdavidlaing

The price history service occasionally returns bars such that the close of a bar is not equal to the open of the next bar (they are very close; but generally different at the 5th decimal place).

Here are the API queries I’m making on https://ciapipreprod.cityindextest9.co.uk/TradingAPI

var userName = "INSERT_YOUR_USER";
doPost('/session',{ "UserName": userName, "Password": "password"}, function (data, textCode) {
    setRequestHeader("UserName", userName);
    setRequestHeader("Session", data.Session);
    //Price history

And a sample of the results (for ‘/market/80904):

4: {BarDate:/Date(1312840020000)/, Close:1.41727, High:1.41745, Low:1.4168, Open:1.41682}
5: {BarDate:/Date(1312840080000)/, Close:1.41731, High:1.41743, Low:1.41725, Open:1.41725}
6: {BarDate:/Date(1312840140000)/, Close:1.41759, High:1.4176, Low:1.41732, Open:1.41736}
7: {BarDate:/Date(1312840200000)/, Close:1.41761, High:1.41761, Low:1.41758, Open:1.41761}

Is this correct behaviour?

Share this post

Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this