- Domov
- Komunita
- Programovanie
- Question on "get-history" API method...
Edit Your Comment
Question on "get-history" API method...
Členom od Oct 05, 2011
3 príspevkov
Oct 18, 2011 at 01:22
Členom od Oct 05, 2011
3 príspevkov
Will it also return specific withdrawals? In the example in the API docs, it only shows a closed trade:
<response error='false' message=''>
<history>
<transaction>
<openDate>03/01/2010 14:13</openDate>
<closeDate>03/01/2010 15:26</closeDate>
<symbol>GBPUSD</symbol>
<action>Buy Limit</action>
<sizing>
<type>lots</type>
<value>0.04</value>
</sizing>
<openPrice>1.48310</openPrice>
<closePrice>1.49340</closePrice>
<tp>1.48810</tp>
<sl>0.00000</sl>
<pips>0.0</pips>
<profit>0.00</profit>
<comment>Best trade ever</comment>
<interest>12.1</interest>
<commission>0</commission>
</transaction>
</history>
</response>
If a withdrawal *would* be returned from this function, what tags would it be wrapped in?
<response error='false' message=''>
<history>
<transaction>
<openDate>03/01/2010 14:13</openDate>
<closeDate>03/01/2010 15:26</closeDate>
<symbol>GBPUSD</symbol>
<action>Buy Limit</action>
<sizing>
<type>lots</type>
<value>0.04</value>
</sizing>
<openPrice>1.48310</openPrice>
<closePrice>1.49340</closePrice>
<tp>1.48810</tp>
<sl>0.00000</sl>
<pips>0.0</pips>
<profit>0.00</profit>
<comment>Best trade ever</comment>
<interest>12.1</interest>
<commission>0</commission>
</transaction>
</history>
</response>
If a withdrawal *would* be returned from this function, what tags would it be wrapped in?
Členom od Jul 31, 2009
1449 príspevkov
Oct 18, 2011 at 12:15
Členom od Jul 31, 2009
1449 príspevkov
It would be wrapped with the same tags. Check the 'action' tag for the transaction type.
Členom od Oct 05, 2011
3 príspevkov
Oct 18, 2011 at 15:25
Členom od Oct 05, 2011
3 príspevkov
Would the action be 'Withdrawal'?
I'm referring to actually withdrawing money from the account, not a losing trade (which I've noticed MT also calls a withdrawal for whatever reason).
With that in mind, what tag would the $ amount withdrawn from the account be wrapped in?
Thank you for your insight!
I'm referring to actually withdrawing money from the account, not a losing trade (which I've noticed MT also calls a withdrawal for whatever reason).
With that in mind, what tag would the $ amount withdrawn from the account be wrapped in?
Thank you for your insight!
Členom od Jul 31, 2009
1449 príspevkov
Oct 19, 2011 at 07:47
Členom od Jul 31, 2009
1449 príspevkov
Yes, it would be a withdrawal. The types are marked the same as in your Metatrader platform. The 'withdrawal' definition may change from broker to broker.
All the other tags are the same - the 'profit' tag would represent the amount of the withdrawal.
All the other tags are the same - the 'profit' tag would represent the amount of the withdrawal.
Členom od Oct 05, 2011
3 príspevkov
Oct 20, 2011 at 03:52
Členom od Oct 05, 2011
3 príspevkov
Interesting, thank you for that clarity Ethan.
*Komerčné použitie a spam nebudú tolerované a môžu viesť k zrušeniu účtu.
Tip: Uverejnením adresy URL obrázku /služby YouTube sa automaticky vloží do vášho príspevku!
Tip: Zadajte znak @, aby ste automaticky vyplnili meno používateľa, ktorý sa zúčastňuje tejto diskusie.