ccxt | PHP cryptocurrency trading library with support | Cryptography library
kandi X-RAY | ccxt Summary
kandi X-RAY | ccxt Summary
A PHP cryptocurrency trading library with support for more than 110 bitcoin/altcoin exchanges
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Fetches data from a URL .
- Fetches market data
- Fetches market currencies
- Returns the service description .
- Parse a wallet entry
- Parse v2 order
- Fetches all crypto currencies
- Fetch a currency by ID
- Fetch orders helper
- Return the service description .
ccxt Key Features
ccxt Examples and Code Snippets
Community Discussions
Trending Discussions on ccxt
QUESTION
Is there a specific binance futures API endpoint with which you automatically close all positions? There is such an option in the GUI. Right now I can only imagine getting amounts of all positions and than selling that amount, but is there an easier way?
Preferably I would like to be able to call in either the ccxt library or the python-binance library.
...ANSWER
Answered 2021-Jun-09 at 13:17Binance API has a DELETE /fapi/v1/allOpenOrders endpoint that requires a pair symbol.
ccxt wraps this endpoint in the cancel_all_orders() function, which requires a pair symbol as well.
So at least you don't have to loop through all positions. But you'll need to loop through all pairs. Or just the pairs with open orders, if you have this information.
QUESTION
Is there a possibility to get the original response from the exchange (e.g. Binance)?
Since CCXT offers the possibility to overrride API params, I thought it might be possible to get the original response as well.
Right now I'm overriding the CCXT module itself - maybe there is a better solution than that?
...ANSWER
Answered 2021-May-24 at 00:49CCXT will store the most recent response in exchange.last_http_response
(as a text string) and exchange.last_json_response
(as a JSON-decoded object, if applicable). So, after executing a RESTful call, you can see the response in one or both of those properties:
QUESTION
I was analysing crypto data using a library called ccxt. With ccxt, I can easily get candlestick for crypto datafeed into dataframe:
...ANSWER
Answered 2021-May-05 at 12:13You can try retaining your code of aggregating a list of dataframes and then concat them after the loop, like below:
QUESTION
I am using python 3.9.2. I wanted to install ccxt package in a virtual environment I have created
...ANSWER
Answered 2021-Apr-29 at 14:41I found and answer which I posted at the bottom of question itself.
QUESTION
I'm running an algorithm to predict prices and enter trades for me using the ccxt API in python. I wish to execute a trailing stop loss order and I enter such a long position like this:
...ANSWER
Answered 2021-Apr-24 at 12:29Binance REST API doesn't support TRAILING_STOP_MARKET
, see "Order types" in the Enum definitions.
If you want to simulate a trailing stop order, you'll need to subscribe to the trade stream and keep recalculating your stop price. When the current market price reaches the stop price, submit a new order.
QUESTION
I'm using CCXT for some API REST calls for information and websockets. It's OK for 1 user, if I wanted to have many users using the platform, How would I go about an inhouse solution?
Currently each chart is either using websockets or rest calls, if I have 20 charts then thats 20 calls, if I increase users, then thats 20x whatever users. If I get a complete coin list with realtime prices from 1 exchange, then that just slows everything down.
Some ideas I have thought about so far are:
- Use proxies with REST/Websockets
- Use timescale DB to store the data and serve that OR
- Use caching on the server, and serve that to the users
Would this be a solution? There's got to be a way to over come rate limiting & reducing the amount of calls to the exchanges.
...ANSWER
Answered 2021-Apr-22 at 12:30Probably, it's good to think about having separated layers to:
- receive market data (a single connection that broadcast data to OHLC processors)
- process OHLC histograms (subscribe to internal market data)
- serve histogram data (subscribe to processed data)
The market data stream is huge, and if you think about these layers independently, it will make it easy to scale and even decouple the components later if necessary.
With timescale, you can build materialized views that will easily access and retrieve the information. Every materialized view can set a continuous aggregate policy based on the interval of the histograms.
Fetching all data all the time for all the users is not a good idea. Pagination can help bring the visible histograms first and limit the query results to avoid heavy IO in the server with big chunks of memory.
QUESTION
I’m learning python and dash and I’m building an application for monitoring my trading.
I’ve adapted the code from : “Live Updating Components” example (Orbital Satellite). It works well on jupyter notebook and repl.it but I have an error when I try it on my computer :
"Traceback (most recent call last): File "orbital.py", line 62, in Input('interval-component', 'n_intervals'))"
“The input argument interval-component.n_intervals must be a list or tuple of dash.dependencies.Inputs.”
I don’t understand why
Here is my code :
...ANSWER
Answered 2021-Apr-04 at 15:14As the error is trying to say, you need to wrap your Input
in a list, like this:
QUESTION
Hi i try to get data from api and record it to dataframe but not work. how can i fix it?
edit. i fetch data by ccxt lib to create order to exchange.
data info on buy
###create_buy_order : {'info': {'avgFillPrice': None, 'clientId': None, 'createdAt': '2020-11-19T13:30:25.969907+00:00', 'filledSize': 0.0, 'future': None, 'id': 14955364871, 'ioc': False, 'liquidation': False, 'market': 'ETHBEAR/USD', 'postOnly': False, 'price': 0.02378, 'reduceOnly': False, 'remainingSize': 10.0, 'side': 'buy', 'size': 10.0, 'status': 'new', 'type': 'limit'} # , 'id': '14955364871', 'clientOrderId': None, 'timestamp': 1605792625969, 'datetime': '2020-11-19T13:30:25.969Z', 'lastTradeTimestamp': None, 'symbol': 'ETH
In csv file only have columnsn not get values on row.
...ANSWER
Answered 2020-Nov-21 at 18:11set order by yourself using double bracket
QUESTION
json data is coming from the remote server with ccxt.
How can I get the current balance of "NEO" in it?
...ANSWER
Answered 2020-Nov-18 at 19:06Loop through the list and search for NEO
QUESTION
I have a dataframe that I created from a Data Dictionary format in the following way:
...ANSWER
Answered 2020-Jun-24 at 01:51I am 99% sure you get the result you want by just doing this:
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install ccxt
PHP requires the Visual C runtime (CRT). The Microsoft Visual C++ Redistributable for Visual Studio 2019 is suitable for all these PHP versions, see visualstudio.microsoft.com. You MUST download the x86 CRT for PHP x86 builds and the x64 CRT for PHP x64 builds. The CRT installer supports the /quiet and /norestart command-line switches, so you can also script it.
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page