Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing trades in trade history /api/v4/spot/my_trades #64

Open
phips28 opened this issue Feb 25, 2022 · 16 comments
Open

Missing trades in trade history /api/v4/spot/my_trades #64

phips28 opened this issue Feb 25, 2022 · 16 comments
Assignees

Comments

@phips28
Copy link

phips28 commented Feb 25, 2022

The Gate.io Support Jerome sent me here to create an issue, so I hope you can help me and fix the bug in your API

I am fetching the full trade history from Gate.io. But I am missing OMI/USDT and BTC/USDT trade from 2021-09-11.
I can see them in the frontend, but not via API.

This is the API request I do:

GET https://api.gateio.ws/api/v4/spot/my_trades?currency_pair=OMI_USDT&limit=1000&page=1&from=1630454400&to=1633046400
Timerange from 2021-09-01 till 2021-10-01 => so there must be the trade from 2021-09-11 in.
Response: []

The red marked txs are missing in the API:
image

@phips28
Copy link
Author

phips28 commented Mar 3, 2022

@gateio can you please help here?

@revilwang
Copy link
Collaborator

Sorry for the late reply. Could you please send me your UID?

@phips28
Copy link
Author

phips28 commented Mar 4, 2022

hi @revilwang thx for your reply.
I asked our client for the UID. We (blockpit.io) dont store it in our DB.
I will answer here.

@phips28
Copy link
Author

phips28 commented Mar 8, 2022

@revilwang where can I send you the UID on a safe channel? do you have a gateio email address?

@revilwang
Copy link
Collaborator

@phips28 You can send it to dev@mail.gate.io

@revilwang revilwang self-assigned this Mar 9, 2022
@revilwang
Copy link
Collaborator

The data is missing from the API backend. It is restored.

@phips28
Copy link
Author

phips28 commented Mar 9, 2022

@revilwang I tested with OMI/USDT but the sell trade from 2021-09-11 is still not there:
image

fetch single market; market: OMI/USDT 2021-09-01T00:00:00.000Z to 2021-10-01T00:00:00.000Z

handleRestResponse:
 gateio GET https://api.gateio.ws/api/v4/spot/my_trades?currency_pair=OMI_USDT&limit=1000&page=1&from=1630454400&to=1633046400 200 OK
ResponseHeaders:
 {
....
  Date: 'Wed, 09 Mar 2022 15:08:21 GMT',
  'X-Request-Id': '[0da56044-4272757224]'
}
ResponseBody:
 [
{"id":"1608598159","create_time":"1631266999","create_time_ms":"1631266999077.752200","currency_pair":"OMI_USDT","side":"buy","role":"taker","amount":"1746.3585611","price":"0.003588","order_id":"76286564614","fee":"3.4927171222","fee_currency":"OMI","point_fee":"0","gt_fee":"0"},
{"id":"1608598158","create_time":"1631266999","create_time_ms":"1631266999077.555000","currency_pair":"OMI_USDT","side":"buy","role":"taker","amount":"409.665","price":"0.003588","order_id":"76286564614","fee":"0.81933","fee_currency":"OMI","point_fee":"0","gt_fee":"0"},
{"id":"1608598157","create_time":"1631266999","create_time_ms":"1631266999077.334000","currency_pair":"OMI_USDT","side":"buy","role":"taker","amount":"22302.759","price":"0.003587","order_id":"76286564614","fee":"44.605518","fee_currency":"OMI","point_fee":"0","gt_fee":"0"},
{"id":"1608598156","create_time":"1631266999","create_time_ms":"1631266999077.122000","currency_pair":"OMI_USDT","side":"buy","role":"taker","amount":"50891.6194389","price":"0.003586","order_id":"76286564614","fee":"101.7832388778","fee_currency":"OMI","point_fee":"0","gt_fee":"0"},
{"id":"1608598155","create_time":"1631266999","create_time_ms":"1631266999076.914000","currency_pair":"OMI_USDT","side":"buy","role":"taker","amount":"24703.896","price":"0.003575","order_id":"76286564614","fee":"49.407792","fee_currency":"OMI","point_fee":"0","gt_fee":"0"},
{"id":"1608598154","create_time":"1631266999","create_time_ms":"1631266999076.675800","currency_pair":"OMI_USDT","side":"buy","role":"taker","amount":"417.809","price":"0.003573","order_id":"76286564614","fee":"0.835618","fee_currency":"OMI","point_fee":"0","gt_fee":"0"},
{"id":"1608598153","create_time":"1631266999","create_time_ms":"1631266999076.351800","currency_pair":"OMI_USDT","side":"buy","role":"taker","amount":"22390.148","price":"0.003573","order_id":"76286564614","fee":"44.780296","fee_currency":"OMI","point_fee":"0","gt_fee":"0"},
{"id":"1608598152","create_time":"1631266999","create_time_ms":"1631266999076.046900","currency_pair":"OMI_USDT","side":"buy","role":"taker","amount":"3712.521","price":"0.003572","order_id":"76286564614","fee":"7.425042","fee_currency":"OMI","point_fee":"0","gt_fee":"0"},
{"id":"1608598151","create_time":"1631266999","create_time_ms":"1631266999075.746000","currency_pair":"OMI_USDT","side":"buy","role":"taker","amount":"348.305","price":"0.003568","order_id":"76286564614","fee":"0.69661","fee_currency":"OMI","point_fee":"0","gt_fee":"0"},
{"id":"1608598150","create_time":"1631266999","create_time_ms":"1631266999075.524200","currency_pair":"OMI_USDT","side":"buy","role":"taker","amount":"11731.087","price":"0.003567","order_id":"76286564614","fee":"23.462174","fee_currency":"OMI","point_fee":"0","gt_fee":"0"},
{"id":"1608598149","create_time":"1631266999","create_time_ms":"1631266999075.267000","currency_pair":"OMI_USDT","side":"buy","role":"taker","amount":"293.436","price":"0.003567","order_id":"76286564614","fee":"0.586872","fee_currency":"OMI","point_fee":"0","gt_fee":"0"}
]

Also tested BTC/USDT now, also not there:
image

fetch single market; market: BTC/USDT 2021-09-01T00:00:00.000Z to 2021-10-01T00:00:00.000Z
handleRestResponse:
 gateio GET https://api.gateio.ws/api/v4/spot/my_trades?currency_pair=BTC_USDT&limit=1000&page=1&from=1630454400&to=1633046400 200 OK
ResponseHeaders:
 {
 ....
  Date: 'Wed, 09 Mar 2022 15:13:33 GMT',
  'X-Request-Id': '[3f1e49eb-4273278109]'
}
ResponseBody:
 []

@phips28
Copy link
Author

phips28 commented Mar 9, 2022

We also have another user with a similiar issue, where we are not able to fetch trades that happened on 2021-09-29.
Maybe related?
image
Screenshots are from cointracking.info, and were imported last year. So it already worked via API, but now they do not appear anymore via API. :(

@revilwang
Copy link
Collaborator

Sorry for the trouble, you can send uid and data range you have doubt with to the email above. I’ll handle them together

@phips28
Copy link
Author

phips28 commented Mar 9, 2022

I hope you received my email.

@revilwang
Copy link
Collaborator

No, the email is not received. Are you sending it to dev@mail.gate.io

@revilwang
Copy link
Collaborator

Both users' missing trades have been restored. You can check it.

@phips28
Copy link
Author

phips28 commented Mar 10, 2022

@revilwang thank you for restoring. We can confirm that we are receiving those txs.

Was this a general fix for all users? or just for the 2 I sent you?

@revilwang
Copy link
Collaborator

Not for now. If you find any other data missing. You can directly email to dev@mail.gate.io.

@phips28
Copy link
Author

phips28 commented Mar 10, 2022

ok but can you restore all data to be 100% sure no user is affected by this?
We have a lot of users at blockpit.io (tax reporting) and not every user can go through their trade history and look at the trades one-by-one to find out if there is something missing.
So I think the user (and also us) expects to have a 100% correct history out of the API.
Can you please make sure this is going to work for every user. Thank you!

@revilwang
Copy link
Collaborator

I understand your concern. We'll scan through all possible missing data. But it may take a little time. Before this is done, you can report any doubt you have. Sorry for the trouble

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants