Comments (2)
I am seeing the same problem, but it does not appear to be a problem with the library, but the API itself.
My attempted call to get the 1 day kline,
console.log( marketApi.klines( "KOINUSDT", "1d", {startTime: 1671926400000, limit: 1} ) );
Returns:
[
[
1676505600000,
'0.5389',
'0.5389',
'0.4901',
'0.4987',
'23355.63',
1676592000000,
'11724.4131'
]
]
When I use curl, I get the same thing:
curl -H "Content-Type: application/json" -H "X-MEXC-APIKEY: XXXXXXXXXXXXXXXX" https://api.mexc.com/api/v3/klines\?symbol=KOINUSDT\&interval=1d\&limit=1\&startTime=1671926400000 | jq
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 91 100 91 0 0 382 0 --:--:-- --:--:-- --:--:-- 382
[
[
1676505600000,
"0.5389",
"0.5389",
"0.4901",
"0.4983",
"23800.63",
1676592000000,
"11946.1738"
]
]
I have tried passing in startTime
as a string as well as the names start_time
and StartTime
. No combination is working.
It would appear that the API is not either documented incorrectly or not respecting the startTime
and endTime
parameters.
For the time being, I can get the information I need by cranking up the limit and iterating through the results, but that is neither efficient for my script, nor MEXC's API server.
from mexc-api-sdk.
I have a similar problem on Python
spot.klines('PRAREUSDT', '1d', {'limit': 1})
but the function returns empty array when I pass start and end time.
I have tried many things to get a proper response but no luck
from mexc-api-sdk.
Related Issues (20)
- Simple buy order with ccxt library that work with mexc exchanger
- error 500!!! or chunk chars
- does not return trade list older than 7 days
- Cannot get more than 1000 bars Kline/Candlestick Data HOT 1
- (Not a noob issue) ModuleNotFoundError HOT 3
- The documentation for this project is wrong
- is there api to get permission?
- TAR_BAD_ARCHIVE: Unrecognized archive format
- Withdraw currency /api/v3/capital/withdraw/apply
- MEXC package won't work
- account_info not working
- ModuleNotFoundError: No module named 'mexc_sdk' on Python HOT 1
- new code HOT 1
- Spot client fails to construct HOT 1
- python example for portfolio generator
- orderType = 'STOP_LOSS_LIMIT' gives me a {"msg":"invalid type","code":500}
- Python Issue! Failed to place market order. Error: 'Spot' object has no attribute 'newOrderTest' HOT 1
- buying/selling on Spot
- Possible to use API for futures?
- Is there api to get all open orders not just for one symbol
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mexc-api-sdk.