Install via Composer:
composer require ewertondaniel/bitfinex-php-sdk
Public example:
use EwertonDaniel\Bitfinex\Facades\Bitfinex;
$status = Bitfinex::public()->platformStatus();
echo $status->content->status; // "operative" or "maintenance"
Authenticated example (Laravel, via config/env):
use EwertonDaniel\Bitfinex\Facades\Bitfinex;
$auth = Bitfinex::authenticated()->generateToken();
$wallets = $auth->wallets()->get();
foreach ($wallets->content['wallets'] as $wallet) {
// ...
}
More examples in the usage guide.
The Bitfinex PHP SDK is a lightweight PHP library designed to simplify interaction with the Bitfinex REST API. This SDK allows developers to easily integrate advanced cryptocurrency trading functionalities into PHP applications. Whether building automated trading bots, monitoring market trends, or developing custom trading platforms, this SDK makes the integration with Bitfinex straightforward and efficient.
The Bitfinex API provides access to the full suite of features available on the Bitfinex platform. It allows users to retrieve market data, manage account details, place orders, and more. Designed for speed, the API is optimized to support high-frequency trading and low-latency data streaming, making it an essential tool for advanced trading strategies.
For detailed information on endpoints, methods, and usage guidelines, refer to the Bitfinex API Documentation.
t prefix (e.g., tBTCUSD for Bitcoin to USD).Any use of the Bitfinex API is subject to the API Terms of Service. All API keys and interactions are at your own risk and expense. iFinex Inc. is not responsible for any losses or damages resulting from the use of this SDK or the Bitfinex API.
Wallets — https://docs.bitfinex.com/reference/rest-auth-wallets
Orders — https://docs.bitfinex.com/reference/rest-auth-retrieve-orders
Positions — https://docs.bitfinex.com/reference/rest-auth-positions
Funding — https://docs.bitfinex.com/reference/rest-auth-funding-offers
Account Actions — https://docs.bitfinex.com/reference/rest-auth-info-user
Merchants (Bitfinex Pay) — https://docs.bitfinex.com/reference/rest-auth-ext-pay-invoice-create
PublicBitfinexResponse delegates mappings to classes in Http/Responses/Public/Transformers via TransformerFactory.conf endpoint uses ConfigsTransformer with strategies by mode (map/list/info:*).RequestBuilder offers a fluent API for headers/query/body; for GET methods, body is not sent.JsonAdapter::transform() is final; UrlAdapter/PathAdapter only define getFilePath().These patterns keep low coupling, testability, and safe SDK evolution.
Contributions are welcome. See the contribution guide for details.
Run unit tests (Pest):
vendor/bin/pestvendor/bin/pest tests/Unit/PublicLint & static analysis:
composer lint (Pint + PHPStan)Format:
composer format (Pint)This package is licensed under the MIT License.
Ewerton Daniel - contact@ewertondaniel.work
If this project helps you, consider sending some Monero:
89ynYeog7vt6san1FENHDQhn4RnG9sR2f2jj5DSpgY6q18sjQcyRoYYEpFEFQDaJ3ajjRXaMnikm1P2xKPK4jEwsMeK5o6Q
How can I help you explore Laravel packages today?