Jump to content


  • Content count

  • Joined

  • Last visited

  • Days Won


Physicsman last won the day on January 9

Physicsman had the most liked content!


About Physicsman

  • Rank

Profile Information

  • Gender
  • Location
    London, Great Britain

Recent Profile Visitors

1,117 profile views
  1. Prices for multiple markets

    Hello, 1) No, we don't have any calls where the user can pull prices for multiple markets in a single call. Throttling generally occurs when there are a large number of calls within a short time frame: 500 calls within 5 seconds. If you are only calling 15 markets that should be fine. 2) It'll mainly be limited by your internet connection and computer hardware, since each market requires bandwidth and processing power from your PC. The more simultaneous subscriptions you have, the more resources will be used. If you have a fast modern PC and a broadband internet connection, you should be able to subscribe to dozens of markets simultaneously without too much of a probelem. Kind Regards, PM
  2. ClientAccountMargin updates

    Hi, If you have open positions, then the stream updates is dependent upon your account operator. Generally, this will be between 10 - 30 seconds between each update. Kind Regards, PM
  3. Hi, Since the development backlog is an internal system only, clients won't be able to track what is on there. I should also note that the request still has to be evaluated by the backlog owner as to whether it is something the API team will implement - the possibility exists that it could be rejected. The other thing to note is that even if accepted, it will be prioritised against all the other items the team have scheduled currently. Given what they are currently working on, I'd estimate that if the request is accepted, it would be in the order of months rather than weeks. On your account history retrieval, lets check that the account is storing the trade history information and something hasn't happened to it. Please login to our Web Trader platform using your account and open the Reports component from the Workspace menu. Select the More History tab. Enter a "Start" date say a year agao or longer, and leave the "end" date as today. Click Search. Does this procedure return all the trades/orders history for your account from the selected period? Kind Regards, PM
  4. Hi, Not having buy/sell to open flag is not in the API because it was never needed before, or at least was never asked for by anyone until now. I'll pass on this request to the API team whether they could add this in for a future update. Your trade history request should look similar to what is shown below. Note the username and session authentication informatoin is supplied in the header. I've selected a From date 2 years ago of June 2018. https://ciapi.cityindex.com/TradingApi/order/tradehistory?MaxResults=10000&from=1529038800
  5. Hi Jflaggs, In answer to your question: Unfortunately, the answer is you cannot. The historical trade information does not contain anything on the account open position state prior to each trade. No information is given as to whether you were flat in the market or already long 2 for example. The historical trade information is mainly: Buy/Sell placed in market X with quantity Y at price Z along with the time/date stamp for the transaction. Kind Regards, PM
  6. Hello Jflaggs, Determing which trades are opening can be done by inference - check whether the RealisedPnl field is null. Closing trades all have a value for RealisedPnl, whereas an opening trade has null. Kind Regards, PM
  7. Hi Keller, Let's try 2 things to investigate. 1) Please login with your Live account using our browser based Web Trader platform and perform the same search you are doing with the API. DOes this return any results? Since all our trading platforms use the API, we can attempt to eliminate whether this is an account/API problem with this step. In the meantime: 2) Please send me the header/body of the Search request call you are making for with your Live and Demo accounts. I can check the syntax/formatting to make sure that everything is correct to see if the problem is in the search call. Many thanks, PM
  8. Distance at placing an order

    Hello, Yes, if you make an API MarketInformation call, once of the returned fields is "MinDistance". This shows the minimum distance from the current buy/sell price where you can place an order. Kind Regards, PM
  9. Hello, For trade queries please contact the Client Services team. I am not able to check these type of queries. Kind Regards, PM
  10. Hello, In this case, then the only way is to subscribe to the Order stream and listen for updates to your orders. This will definitively inform you which order has triggered. Kind Regards, PM
  11. wcf-date format

    Hello, We are using the Unix timestamp in milliseconds, rather than in seconds. That is why there is a factor of 1000 in the number. Kind Regards, PM
  12. Hello, You can use a ListTradeHistory call, as this returns orders with a status of (3 - Open, 9 - Closed), and includes orders that were a trade / stop / limit order. The returned results include a RealisedPnL field, and also the price at which the order was executed. Kind Regards, PM
  13. Hello, Variant 1: It is not posssible to set the same StopLoss and TakeProfit prices for both the Buy and Sell legs in yoru request. This is because for a Buy trade, the TakeProfit has to be above the current market price and the StopLoss must be below the current market price. For a Sell trade it is the other way around. The TakeProfit must be below current market price and the StopLoss must be above current market price. We do not have an order type in the system that automatically achieves what you are looking to do. You will have to write custom code that triggers the orders when certain conditions are met as you have described them. Variant 2: Again, there are nor order types in our system to handle this case. You will have to write custom code to send market orders when your conditions are met in order to build the postions you want. Kind Regards, PM
  14. Hello @Cinemizer, Your account is papered under the FOREX.com UK brand, which is setup to be in pound sterling. However, the account currency of your account is in Euros. Whenever you are calling the GetClientAccountMargin call, your cash value is converted from GBP to EUR using the latest live cross-currency rate. That is why with each call you see your cash balance change by a little bit, due to the constantly changing EUR/GBP exchange rate. If you use the streamed cash balance via Lightstreamer, that will resolve the issue. Kind Regards, PM
  15. Hover you rmouse pointer over my user name on one of my posts. a popup will appear. At the bottom left is a message icon. Click on that to open a message window. I'll investigate by using your test account to send repeated GET HTTP calls and see what results are returned.