PHPackages                             coinpaprika/dexpaprika-sdk - 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. coinpaprika/dexpaprika-sdk

ActiveLibrary[API Development](/categories/api)

coinpaprika/dexpaprika-sdk
==========================

Official PHP SDK for the DexPaprika API. Access multi-chain DEX data, token prices, and liquidity pools with advanced caching and error handling.

v1.5.0(1mo ago)105[1 PRs](https://github.com/coinpaprika/dexpaprika-sdk-php/pulls)MITPHPPHP &gt;=7.4CI passing

Since Apr 28Pushed 4w ago1 watchersCompare

[ Source](https://github.com/coinpaprika/dexpaprika-sdk-php)[ Packagist](https://packagist.org/packages/coinpaprika/dexpaprika-sdk)[ Docs](https://github.com/coinpaprika/dexpaprika-sdk-php)[ RSS](/packages/coinpaprika-dexpaprika-sdk/feed)WikiDiscussions sdkv1.0.0 Synced 1w ago

READMEChangelog (1)Dependencies (9)Versions (11)Used By (0)

DexPaprika PHP SDK
==================

[](#dexpaprika-php-sdk)

A PHP SDK for interacting with the DexPaprika API, providing access to cryptocurrency DEX data, token information, liquidity pools, and market statistics.

⚠️ Breaking Changes in v1.3.0
-----------------------------

[](#️-breaking-changes-in-v130)

**IMPORTANT**: The global `/pools` endpoint has been deprecated in DexPaprika API v1.3.0. All pool operations now require a network parameter.

### Migration Required

[](#migration-required)

```
// ❌ OLD - No longer works
$pools = $client->pools->getTopPools(['limit' => 10]);

// ✅ NEW - Network-specific approach
$ethereumPools = $client->pools->getNetworkPools('ethereum', ['limit' => 10]);
$solanaPools = $client->pools->getNetworkPools('solana', ['limit' => 10]);
```

**See the [Migration Guide](examples/migration_guide.php) and [CHANGELOG](CHANGELOG.md) for complete details.**

Unified search endpoints (v1.2.0)
---------------------------------

[](#unified-search-endpoints-v120)

`getNetworkPools()`, `filterPools()`, `getTopTokens()` and `filterTokens()` now call the unified `pools/search` and `tokens/search` endpoints (the previous list/filter/top endpoints return `410 Gone`). The public method signatures are unchanged: legacy sort values (for example `volume_usd`, `fdv`) and legacy filter parameter names (for example `volume24hMin`) are mapped to the canonical search names automatically.

These endpoints are cursor-paginated, so the response shape is:

```
$page = $client->pools->getNetworkPools('ethereum', ['limit' => 20]);
$page['results'];        // array of items
$page['has_next_page'];  // bool
$page['next_cursor'];    // string|null

// Fetch the next page with the cursor
$next = $client->pools->getNetworkPools('ethereum', [
    'limit' => 20,
    'cursor' => $page['next_cursor'],
]);
```

The `page` option is still accepted for backward compatibility but is ignored.

Features
--------

[](#features)

- Simple and intuitive PHP interface to all DexPaprika API endpoints
- Access data from 36+ blockchain networks
- Query information about DEXes, liquidity pools, and tokens
- Get detailed price information, trading volume, and transactions
- **Filter pools and tokens** by volume, liquidity, FDV, transactions, and creation date
- **Get top tokens** on any network ranked by volume or other metrics
- **Batch price lookups** for up to 10 tokens in a single request
- Search across the entire DexPaprika ecosystem
- Automatic retry with exponential backoff
- Response caching with PSR-6 compatible interface
- Parameter validation with clear error messages
- Comprehensive documentation

Requirements
------------

[](#requirements)

- PHP 7.4 or higher
- [Composer](https://getcomposer.org/)
- `ext-json`

Installation
------------

[](#installation)

Install via Composer:

```
composer require your-vendor/dexpaprika-sdk-php
```

Basic Usage
-----------

[](#basic-usage)

```
