Dukascopy
 
 
Wiki JStore Search Login

Attention! Read the forum rules carefully before posting a topic.

    Try to find an answer in Wiki before asking a question.
    Submit programming questions in this forum only.
    Off topics are strictly forbidden.

Any topics which do not satisfy these rules will be deleted.

Getting Trade ID?
 Post subject: Getting Trade ID? Post rating: 0   New post Posted: Tue 24 Jun, 2014, 18:03 

User rating: 6
Joined: Tue 02 Jul, 2013, 16:52
Posts: 38
I am doing some semi-automated trading, so I am looking for a way to get, through the API, the Trade ID available in the JForex trade log.
I found only the Position ID with the IOrder.getID().

For a specific position (IOrder), I can get:
- the opening trade with getFillHistory()
- the trades used to partially close a position with getCloseHistory()

But how can I get the TradeID of these trades (as in the Jforex trade log)?
There was a similar question in the forum, but if I am not mistaken the replies didn't answer that specific point.

Thank you in advance


 
The Best Answer  Post subject: Re: Getting Trade ID? Post rating: 0   New post Posted: Wed 25 Jun, 2014, 12:01 
User avatar

User rating:
Joined: Fri 31 Aug, 2007, 09:17
Posts: 6139
fxbird wrote:
But how can I get the TradeID of these trades (as in the Jforex trade log)?
This information is not available from API.
fxbird wrote:
Also, second question: why does the ICloseOrder date change over time without any new trade?
Could you provide more information about the case? What actions were done/attempted with the given position? Were there any disconnects around the changed close time?


 
 Post subject: Re: Getting Trade ID? Post rating: 0   New post Posted: Wed 25 Jun, 2014, 12:07 

User rating: 6
Joined: Tue 02 Jul, 2013, 16:52
Posts: 38
API Support wrote:
This information is not available from API.
Ok, thank you for the answer. I will find a workaround in my code.
fxbird wrote:
Also, second question: why does the ICloseOrder date change over time without any new trade?
API Support wrote:
Could you provide more information about the case? What actions were done/attempted with the given position? Were there any disconnects around the changed close time?
It's stange because after I got the ICloseOrder for that position a few other times, the date was correct (this is why I deleted that part from my post). I don't think there was any disconnect around that time.
If I see this behavior again, I will open a new post.

Thank you API support :)


 

Jump to:  

  © 1998-2025 Dukascopy® Bank SA
On-line Currency forex trading with Swiss Forex Broker - ECN Forex Brokerage,
Managed Forex Accounts, introducing forex brokers, Currency Forex Data Feed and News
Currency Forex Trading Platform provided on-line by Dukascopy.com