PHPackages                             pangzlab/coingecko-api - 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. pangzlab/coingecko-api

ActiveLibrary[API Development](/categories/api)

pangzlab/coingecko-api
======================

CoinGecko API Client for PHP

v0.2.2(3y ago)332[1 issues](https://github.com/pangz-lab/coingecko-api/issues)MITPHP

Since Dec 15Pushed 2y ago1 watchersCompare

[ Source](https://github.com/pangz-lab/coingecko-api)[ Packagist](https://packagist.org/packages/pangzlab/coingecko-api)[ Fund](https://btcscan.org/address/3MsmELpB8bsYvFJCYKrUpMuoBATVR5eeta)[ Fund](https://ethplorer.io/address/0xa248d188725c3b78af7e7e8cf4cfb8469e46cf3b#)[ RSS](/packages/pangzlab-coingecko-api/feed)WikiDiscussions dev Synced 3w ago

READMEChangelog (6)Dependencies (2)Versions (7)Used By (0)

[ ![chat on Discord](https://camo.githubusercontent.com/b2e5b53de8167e780d6aed23eadfeaeba1ac11a071034bd236327d06745a0760/68747470733a2f2f696d672e736869656c64732e696f2f646973636f72642f313130343638373735383330313230343531323f6c6f676f3d646973636f7264)](https://discord.gg/TK3WHBMk)[ ![follow on witter](https://camo.githubusercontent.com/57573134d2af2337c60a8a50852ff7e6a3c96beaf6e8c3e53d56ed51c1b02cba/68747470733a2f2f696d672e736869656c64732e696f2f747769747465722f666f6c6c6f772f50616e677a35353139323536393f7374796c653d736f6369616c266c6f676f3d74776974746572)](https://twitter.com/intent/follow?screen_name=Pangz55192569) [![](https://camo.githubusercontent.com/0d0d6283f56204d1a046b590c183ff53abde61cc21a463bbd868e31dc288f9ce/68747470733a2f2f6c68332e676f6f676c6575736572636f6e74656e742e636f6d2f666966652f41506735454f593368314d473549336e7932643358394e49544e39474e7579783875506c457535305736476859772d437343505937685f38444e316c39755977384a37596a6d556c397044687555687636797268356776396a454e6f6157516350656251344e63737765544174734642326568575761394554725357434c6f525445566178323747734b474b5642366c4c594e4e313737364d7974707630526c4e5867736e412d316550333059516f7075643263716630594f5475646f2d6865616747346f6965424b424772324134436849725135743055676c4e59706d7a38515f4635376b396d6471386872427a75446d795568644649343074465a74675f76554b495a54595f76643242494a6d476b5a5a336e754d4d795a624f4f4d686753544d787a6c70623364413233476432796d4247664e6f62515a4f613468424f70645f58786962466f7835454f514f64395870536268645074304549417a584562347156734d4a345f4e4d57374f45646b304a51416a614173467a5a7656594c2d754b46752d767a575346675f4752577465446b55555968763630563148327a726d416644644e31306c4535593961694d6279632d363258537a614374474277536d6d6650386943644d505f52734a7175767157484a5445484b57366d4943384258624d71447538696554735571633876655242664852676e316941316c557977414255454c7941414e4d43715a34353076366e44594f436952584656654968392d4f334739507a476759753756306f374d534442684c2d3359306b454e79637349717a766e50534251583338424f4b67503737696e386158553975427a5332373543446f654356616c6f4e777832705a4f58566d4c466b37795f79424841726d3356443763746677505f4e7a4f6b4338347a4e636e3251567963676d426473586c554c6a5f512d504f5832575f4c4d37543454784c516b6f416e354234537642696b544e2d4c655f476532576b516b4963413755335f6a38475579775253595872386d373878655a4f445769397a4a4546556663387a59742d31395059637278305946536976774f714f7870496d2d49456d367834767961706a422d37582d6c6a786332547a6557714f5368586b796c35674b4b304576642d3055366854564e5f6d4c5f755057416c76574c73334c434b7539495a35625644456d4a567442737045687864726a51516a4e71757230316734564d793359795f4b684e69656e74755f414a6d376e644e41654151416f4b6667695574514e727459333036363438736c7252644b444f74356e544c57694855577658635571683675354b79544931594e426e65485179576b32457868784955465041693251556e7a6575323149424b556f656c65394244474b456f4f7a346456334a31716769302d3743316b767657746f78786e4c357a2d394c53777441455731766177356945793379684163624e396e724b744543304f3735653358485232655874344e4b784246376467645758396c535f6c6c736c497376773372467839564f4c6663434d37314854434f3374637a6c66386162784867315236546c4b574f47667161594f426471495271505046317361674c5a766265373575496a52626e437742615274566c345a317337513330495f384a6571326f4a52436e59516367626a7058527670436c4566686c4a54373679626f3968543261475f514645303153777074595132412d62746e776f396a696d48306863347649515852315f704d464851613632726432685369546c6135716f393557715451576f567462573535684e3268374c54463449426d314554596f38314b46704d3148547a5952374c5a514f514d73325f4261556143514265744f6d49575a4b684c57525a43385f58334f5653526f6b546a36787558746f7477634862586c6e363631495458732d317943786467576d70494c39326d506a4d6c6c6a4d55415f6b514a727530735f6c6d2d444571645a6146716d756a3466644e71476a5a75454e312d4651675652642d636f5348504b64344632525932646a7541544e42745155356e497757676d2d7475584d36594858334b7a6c694f7031676c517a5555526b4b56615571332d6c78676668593449785242676d4872773d77313836322d68393638)](https://camo.githubusercontent.com/0d0d6283f56204d1a046b590c183ff53abde61cc21a463bbd868e31dc288f9ce/68747470733a2f2f6c68332e676f6f676c6575736572636f6e74656e742e636f6d2f666966652f41506735454f593368314d473549336e7932643358394e49544e39474e7579783875506c457535305736476859772d437343505937685f38444e316c39755977384a37596a6d556c397044687555687636797268356776396a454e6f6157516350656251344e63737765544174734642326568575761394554725357434c6f525445566178323747734b474b5642366c4c594e4e313737364d7974707630526c4e5867736e412d316550333059516f7075643263716630594f5475646f2d6865616747346f6965424b424772324134436849725135743055676c4e59706d7a38515f4635376b396d6471386872427a75446d795568644649343074465a74675f76554b495a54595f76643242494a6d476b5a5a336e754d4d795a624f4f4d686753544d787a6c70623364413233476432796d4247664e6f62515a4f613468424f70645f58786962466f7835454f514f64395870536268645074304549417a584562347156734d4a345f4e4d57374f45646b304a51416a614173467a5a7656594c2d754b46752d767a575346675f4752577465446b55555968763630563148327a726d416644644e31306c4535593961694d6279632d363258537a614374474277536d6d6650386943644d505f52734a7175767157484a5445484b57366d4943384258624d71447538696554735571633876655242664852676e316941316c557977414255454c7941414e4d43715a34353076366e44594f436952584656654968392d4f334739507a476759753756306f374d534442684c2d3359306b454e79637349717a766e50534251583338424f4b67503737696e386158553975427a5332373543446f654356616c6f4e777832705a4f58566d4c466b37795f79424841726d3356443763746677505f4e7a4f6b4338347a4e636e3251567963676d426473586c554c6a5f512d504f5832575f4c4d37543454784c516b6f416e354234537642696b544e2d4c655f476532576b516b4963413755335f6a38475579775253595872386d373878655a4f445769397a4a4546556663387a59742d31395059637278305946536976774f714f7870496d2d49456d367834767961706a422d37582d6c6a786332547a6557714f5368586b796c35674b4b304576642d3055366854564e5f6d4c5f755057416c76574c73334c434b7539495a35625644456d4a567442737045687864726a51516a4e71757230316734564d793359795f4b684e69656e74755f414a6d376e644e41654151416f4b6667695574514e727459333036363438736c7252644b444f74356e544c57694855577658635571683675354b79544931594e426e65485179576b32457868784955465041693251556e7a6575323149424b556f656c65394244474b456f4f7a346456334a31716769302d3743316b767657746f78786e4c357a2d394c53777441455731766177356945793379684163624e396e724b744543304f3735653358485232655874344e4b784246376467645758396c535f6c6c736c497376773372467839564f4c6663434d37314854434f3374637a6c66386162784867315236546c4b574f47667161594f426471495271505046317361674c5a766265373575496a52626e437742615274566c345a317337513330495f384a6571326f4a52436e59516367626a7058527670436c4566686c4a54373679626f3968543261475f514645303153777074595132412d62746e776f396a696d48306863347649515852315f704d464851613632726432685369546c6135716f393557715451576f567462573535684e3268374c54463449426d314554596f38314b46704d3148547a5952374c5a514f514d73325f4261556143514265744f6d49575a4b684c57525a43385f58334f5653526f6b546a36787558746f7477634862586c6e363631495458732d317943786467576d70494c39326d506a4d6c6c6a4d55415f6b514a727530735f6c6d2d444571645a6146716d756a3466644e71476a5a75454e312d4651675652642d636f5348504b64344632525932646a7541544e42745155356e497757676d2d7475584d36594858334b7a6c694f7031676c517a5555526b4b56615571332d6c78676668593449785242676d4872773d77313836322d68393638)

 [![](https://camo.githubusercontent.com/9f82b1ea465351325514357691a183ab5eb720535458580ff9d9c9e07c56489d/68747470733a2f2f70616e677a2d6c61622e6769746875622e696f2f636f75706f6e732f636f696e6765636b6f2d636770616e677a323430322d636f75706f6e2e706e67)](https://camo.githubusercontent.com/9f82b1ea465351325514357691a183ab5eb720535458580ff9d9c9e07c56489d/68747470733a2f2f70616e677a2d6c61622e6769746875622e696f2f636f75706f6e732f636f696e6765636b6f2d636770616e677a323430322d636f75706f6e2e706e67) [ ![](https://camo.githubusercontent.com/962a3731fff7295cd56961e779a2ae5202273661dbc7fd06b2d9bae2a5d8985d/68747470733a2f2f70616e677a2d6c61622e6769746875622e696f2f636f75706f6e732f636770616e677a323430322d636f75706f6e2d75736167652e706e67) ](https://www.coingecko.com/en/api)

coingecko-api
=============

[](#coingecko-api)

Coingecko API client for PHP
----------------------------

[](#coingecko-api-client-for-php)

A simple, intuitive and composable API Client for the [CoinGecko REST API Service](https://www.coingecko.com/en/api/documentation).

API Version Support
-------------------

[](#api-version-support)

- ✔️ API v3
- ✔️ Community Endpoint
- ✔️ Pro Endpoint

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

[](#requirements)

- ✔️ php: 8.x
- ✔️ guzzlehttp/guzzle: ^7.5

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

[](#installation)

The best and the easiest way to use this library is thru [composer](https://getcomposer.org/). You can also download the source directly and require it to your project.

Just take note of the requirements.

### \[ *Composer* \]

[](#-composer-)

[![composer](https://camo.githubusercontent.com/4d24f8cf4e5586adc1732d18cfbbf60b402ed32932f384c063b0da6e3256e53d/68747470733a2f2f676574636f6d706f7365722e6f72672f66617669636f6e2e69636f)](https://camo.githubusercontent.com/4d24f8cf4e5586adc1732d18cfbbf60b402ed32932f384c063b0da6e3256e53d/68747470733a2f2f676574636f6d706f7365722e6f72672f66617669636f6e2e69636f)[ see packagist.org](https://packagist.org/packages/pangzlab/coingecko-api)

```
composer require pangzlab/coingecko-api

```

OR

### \[ *Direct Download* \]

[](#-direct-download-)

#### 📥 [Get it from the release](https://github.com/pangz-lab/coingecko-api/releases)

[](#-get-it-from-the-release)

---

Library
-------

[](#library)

### \[ Classes \]

[](#-classes-)

This library provides 2 main classes which you can use depending on the type of endpoints you are accessing.

24. CoinGeckoUrlBuilder
25. CoinGeckoApiClient

#### 📦 CoinGeckoApiClient

[](#-coingeckoapiclient)

This is the main class that allows building the API endpoints and sending the request.

This is always required.

```
