Skip to content

Commit

Permalink
Major update
Browse files Browse the repository at this point in the history
  • Loading branch information
nathanramoscfa committed Jun 18, 2024
1 parent 83696b2 commit f8b3e8b
Show file tree
Hide file tree
Showing 64 changed files with 8,814 additions and 9,826 deletions.
25 changes: 8 additions & 17 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -113,25 +113,16 @@ Output:
CoinGecko offers various [API plans](https://www.coingecko.com/en/api/pricing) tailored to different user needs. Below
is a summary table of the key features of each plan:

| Plan | Monthly Price | Annual Price (Monthly) | Rate Limit/Min | Call Credits (Monthly |
|------------|----------------|------------------------|----------------|-----------------------|
| Demo | Free | Free | 10-30 | 10K |
| Analyst | $129 | $103 | 500 | 500K |
| Lite | $499 | $399 | 500 | 2M |
| Pro | $999 | $799 | 1000 | 5M |
| Enterprise | Custom Pricing | Custom Pricing | Custom | Custom |
| Plan | Monthly Price | Annual Price (Monthly) | Rate Limit/Min | Call Credits (Monthly) |
|------------|----------------|------------------------|----------------|------------------------|
| Demo | Free | Free | 10-30 | 10K |
| Analyst | $129 | $103 | 500 | 500K |
| Lite | $499 | $399 | 500 | 2M |
| Pro | $999 | $799 | 1000 | 5M |
| Enterprise | Custom Pricing | Custom Pricing | Custom | Custom |

## Quick Start
To initialize the `pycgapi` client, simply run the following code based on your API plan:

**Demo API:**

```python
from pycgapi import CoinGeckoAPI
api = CoinGeckoAPI() # no API key required for public API
```

**Paid Plan API:**
To initialize the `pycgapi` client, simply run the following code:

```python
import keyring
Expand Down
29 changes: 20 additions & 9 deletions docs/source/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -100,11 +100,12 @@ Alternatively, you can install the latest version of ``pycgapi`` directly from t
API Key
=======

You do not need an API key to use the Public API. You will need an API key to use the Pro API. To obtain an API key,
please visit the `CoinGecko API <https://www.coingecko.com/api>`_ page and follow the instructions. This package comes
bundled with `keyring <https://github.com/jaraco/keyring>`_ to save and retrieve your API key securely
without having to hardcode it. To save your API key, simply run the following code in a Python console or Jupyter
Notebook:
You will need an API key to use the Demo API and Pro API. To obtain an API key,
please visit the `CoinGecko API <https://www.coingecko.com/api>`_ page and
follow the instructions. This package comes bundled with
`keyring <https://github.com/jaraco/keyring>`_ to save and retrieve your API key
securely without having to hardcode it. To save your API key, simply run the
following code in a Python console or Jupyter Notebook:

.. code-block:: python
Expand All @@ -120,8 +121,9 @@ Output:

'MY_API_KEY'

CoinGecko offers various `API plans <https://www.coingecko.com/en/api/pricing>`_ tailored to different user needs. Below
is a summary table of the key features of each plan:
CoinGecko offers various `API plans <https://www.coingecko.com/en/api/pricing>`_
tailored to different user needs. Below is a summary table of the key features
of each plan:

+-------------+----------------+------------------------+----------------+-----------------------+
| Plan | Monthly Price | Annual Price (Monthly) | Rate Limit/Min | Call Credits (Monthly)|
Expand All @@ -147,8 +149,17 @@ To initialize the ``pycgapi`` client, simply run the following code based on you

.. code-block:: python
import keyring
from pycgapi import CoinGeckoAPI
api = CoinGeckoAPI() # no API key required for public API
# gets your API key
api_key = keyring.get_password(
'coingecko',
'api_key'
)
# set pro_api=False for paid plans
api = CoinGeckoAPI(api_key, pro_api=False)
**Paid Plan API:**

Expand All @@ -163,7 +174,7 @@ To initialize the ``pycgapi`` client, simply run the following code based on you
'api_key'
)
# must provide api_key and set pro_api=True
# set pro_api=True for paid plans
api = CoinGeckoAPI(api_key, pro_api=True)
**Ping the CoinGecko API server:**
Expand Down
Loading

0 comments on commit f8b3e8b

Please sign in to comment.