PHPackages                             larislackers/php-binance - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. larislackers/php-binance

AbandonedArchivedLibrary[API Development](/categories/api)

larislackers/php-binance
========================

A PHP wrapper for the Binance API endpoints.

1.0.2(8y ago)368.3k211MITPHPPHP &gt;=5.5.9

Since Oct 8Pushed 8y ago3 watchersCompare

[ Source](https://github.com/larislackers/php-binance)[ Packagist](https://packagist.org/packages/larislackers/php-binance)[ Docs](https://github.com/larislackers/php-binance)[ RSS](/packages/larislackers-php-binance/feed)WikiDiscussions master Synced 2mo ago

READMEChangelogDependencies (4)Versions (4)Used By (1)

Larislackers-BinanceApi
=======================

[](#larislackers-binanceapi)

**Larislackers-BinanceApi** is a [Binance.com](https://binance.com) API wrapper for PHP. Moreover, the API wrapper **supports all available functionality** given from Binance **along with sockets**.

**All requests are following the [HTTP/1.1 protocol](https://tools.ietf.org/html/rfc2616) and all responses are returned as a [PSR-7](http://docs.guzzlephp.org/en/stable/psr7.html) [ResponseInterface](http://www.php-fig.org/psr/psr-7/).**

Tests are available after providing your key and secret in the corresponding class.

Install
-------

[](#install)

```
composer require larislackers/php-binance
```

Usage
-----

[](#usage)

*Information on how to obtain your API key and secret from Binance can be found [here](https://support.binance.com/hc/en-us/articles/115000840592-Binance-API-Beta).*

First things first, in order to use the API wrapper you should initialize it with the aforementioned key and secret like this:

```
$bac = new BinanceApiContainer('', '');
```

Then, use the initiated object/var like this:

```
// Get all orders for a symbol (BNB/BTC pair).
$orders = $bac->getOrderBook(['symbol' => 'BNBBTC']);
var_dump($orders->getBody()->getContents());
```

You may find the rest of the supported commands inside the [BinanceApiContainer](https://github.com/larislackers/php-binance/blob/master/src/BinanceApiContainer.php).

Notes
-----

[](#notes)

*All parameters required for each function must be in array format. More information can be found in the comments (phpdoc) and the links to the corresponding functions documented at Binance.*

**Avoid to use hardcoded values**; enums are available (for intervals, types, sides, etc) for consistency and compliance with the Binance API.

**You should use your own logger (like [Sentry](https://sentry.io/welcome/))** and catch `BinanceApiException` for exceptions returned from Binance API and `LarislackersException` for exceptions returned from Websockets.

**Don't reinvent the wheel** by trying to cache results in a request lifecycle with static classes. Use a framework that supports caching (like [Laravel](https://laravel.com/docs/5.5/cache)), an extension (like [Memcached](https://memcached.org/)) or using files. Additional information can be found [here](http://www.php-cache.com/en/latest/).

**More information on how to use the library can be found [here](https://larislackers.github.io/php-binance/).**

*See the official [API documentation](https://github.com/binance-exchange/binance-official-api-docs/blob/master/rest-api.md) for more information about the endpoints and responses.*

License
-------

[](#license)

Larislackers-BinanceApi is open-sourced software licensed under the [MIT license](http://opensource.org/licenses/MIT)

Donations/Support
-----------------

[](#donationssupport)

If you find this library to your liking and enjoy using it, please consider a donation to one of the following addresses:

- BTC: 13rSaL7ze89Pz28fNR9cNCnNVNvLWR3eFt
- ETH: 0x03d4566d13ca7c7b30c39666b1f21ff97bee3f97
- XMR: 49hxHRNwLSdQcXuCcac3ySMnAEuH4BhLWR8NddjHi6QBJHNvj1LqcSg2X8qpTQgsE1brzt37W6dLiiSN6uCj1CwyUPNr8R5

###  Health Score

35

—

LowBetter than 79% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity32

Limited adoption so far

Community19

Small or concentrated contributor base

Maturity60

Established project with proven stability

 Bus Factor1

Top contributor holds 78.9% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~10 days

Total

3

Last Release

3119d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/4f53ac1f5c7054cac474f7d959996cc7c76162b502a5af18e0fea061a9eaa580?d=identicon)[hennett](/maintainers/hennett)

---

Top Contributors

[![ppapadatis](https://avatars.githubusercontent.com/u/5330923?v=4)](https://github.com/ppapadatis "ppapadatis (15 commits)")[![bencagri](https://avatars.githubusercontent.com/u/823521?v=4)](https://github.com/bencagri "bencagri (2 commits)")[![T1l3](https://avatars.githubusercontent.com/u/1226419?v=4)](https://github.com/T1l3 "T1l3 (2 commits)")

---

Tags

binancecryptocurrencycryptocurrency-exchangesphpphp-librarywrapper-apiphpapicryptocurrencyPHP Librarybinancewrapper-apicryptocurrency-exchanges

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/larislackers-php-binance/health.svg)

```
[![Health](https://phpackages.com/badges/larislackers-php-binance/health.svg)](https://phpackages.com/packages/larislackers-php-binance)
```

###  Alternatives

[theodo-group/llphant

LLPhant is a library to help you build Generative AI applications.

1.5k311.5k5](/packages/theodo-group-llphant)[renoki-co/php-k8s

Control your Kubernetes clusters with this PHP-based Kubernetes client. It supports any form of authentication, the exec API, and it has an easy implementation for CRDs.

321669.7k2](/packages/renoki-co-php-k8s)[resend/resend-php

Resend PHP library.

564.7M21](/packages/resend-resend-php)[scriptdevelop/whatsapp-manager

Paquete para manejo de WhatsApp Business API en Laravel

762.6k](/packages/scriptdevelop-whatsapp-manager)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
