GithubHelp home page GithubHelp logo

codenix-sv / coingecko-api Goto Github PK

View Code? Open in Web Editor NEW
132.0 132.0 58.0 188 KB

CoinGecko PHP API client for coingecko.com (V3)

License: MIT License

PHP 100.00%
altcoins coingecko coingecko-api coingecko-client coingecko-php cryptocurrency php

coingecko-api's People

Contributors

btrsco avatar codenix-sv avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

coingecko-api's Issues

Add new API parameter "interval" for coin market-charts

I believe this is quite new, because the documentation is not fully complete yet, but you can add a query parameter "interval" to the endpoint /coins/{id}/market_chart. With that you can set the granularity of the historic data.
You can find it here: https://www.coingecko.com/en/api/documentation
The change required to support this feature is minimal. It would be great if it was supported.
I will submit a Pull Request to update the repository.

Guzzle 7

Hello,

I would like to try this package, but I need Guzzle to be minimum at 7. Do you have any plans to update Guzzle?

[InvalidArgumentException] laravel 5.x

erreur :
[InvalidArgumentException]
Package codenix-sv/coingecko-api has a PHP requirement incompatible with your PHP version, PHP extensions and Compo
ser version

command :
composer require codenix-sv/coingecko-api

green chart image

how can i find 365 days green chart image of a coin like telegram bot ?

cURL error 6: Could not resolve host: api.coingecko.com

cURL error 6: Could not resolve host: api.coingecko.com (see https://curl.haxx.se/libcurl/c/libcurl-errors.html) for https://api.coingecko.com/api/v3/simple/price?ids=bitcoin&vs_currencies=eur

Using this API for a week now, never had problems, since today i get this error when i open pages, using this api.
(Opening the api request https://api.coingecko.com/api/v3/simple/price?ids=bitcoin&vs_currencies=eur manually outside the plugin works)
Any ideas?

Error?

Class Codenixsv\CoinGeckoApi\Exception\TransformResponseException located in ./vendor/codenix-sv/coingecko-api/src/Exceptions/TransformResponseException.php does not comply with psr-4 autoloading standard. Skipping.
Class App\Console\Commands\GetTickersAllExchanges located in ./app/Console/Commands/getTickersAllExchanges.php does not comply with psr-4 autoloading standard. Skipping.

Having an issue with GuzzleHTTP

Hello, i'm getting an error when i use this client.

Uncaught Error: Class 'GuzzleHttp\Client' not found in C:\xampp\htdocs\crypto\coingecko_client\src\CoinGeckoClient.php:39

Please help me to solve this
Thank you

How get server headers for a request?

Hi. Thank you for the library! Tell me, how can I get server headers for a request?

https://api.coingecko.com/api/v3/exchanges?per_page=10

image

Based on this data, I would be able to figure out whether to make more requests and when to stop.

Am I correct in assuming that the library doesn't offer these features right now?

Execption handling

If i try to get coin data there no exists, it will a execption come.

Client error: GET https://api.coingecko.com/api/v3/coins/beluga.fi?tickers=true&market_data=true&sparkline=true` resulted in a 404 Not Found response: {"error":"Could not find coin with the given id"} `

This Execption cant be catcht, because there are come from GUZZLE Client.

How can i catch these exeptions?

Currently i have to change the CoinGeckoClient Constructor and add a new parameter, like

$this->httpClient = $client ?: new Client(['base_uri' => self::BASE_URI, 'http_errors' => false]);

That feel like bad.

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.