Code Monkey home page Code Monkey logo

Comments (4)

jaggedsoft avatar jaggedsoft commented on May 27, 2024 1

I just issued a new release with my favorite function

Get ticker updates for all symbols via WebSocket

$api->ticker(false, function($api, $symbol, $ticker) {
	print_r($ticker);
});

Get ticker updates for a specific symbol via WebSocket

$api->ticker("CDTBTC", function($api, $symbol, $ticker) {
	print_r($ticker);
});

from php-binance-api.

jaggedsoft avatar jaggedsoft commented on May 27, 2024 1

Available in v0.0.12

from php-binance-api.

jaggedsoft avatar jaggedsoft commented on May 27, 2024

minNotional is .002
So this means you must order .002btc worth of CDT at minimum

last price of CDT is 0.00001150
divide minNotional by the price: .002 / 0.00001150
$amount = $minNotional / $lastPrice;
equals 173.91304347826087 units, the minimum you must buy to get .002 btc
roundStep is 1, so you must call ceil($amount) to round it to 174

from php-binance-api.

MuhammadNouman avatar MuhammadNouman commented on May 27, 2024

ok, thanks for quick reply,another thing, from where I can get the latest updated price of an asset using websocket? i.e which websocket endpoint can b used to have a continous look at latest price of an asset

from php-binance-api.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.