Files
OpenBB/openbb_terminal/cryptocurrency/data/README.md
James Maslek eb2c11060d Refactor requests throughout (#4033)
* bump

* Initial function write

* Delete this line from yaml

* Changed all the main things - Need help on tests

* pylint errors

* Tests v0

* Tests v1

* Tests v2

---------

Co-authored-by: andrewkenreich <andrew.kenreich@gmail.com>
2023-01-27 14:01:07 -05:00

949 B
Vendored

Update list of coins

Coingecko

new_categories = {}
for category in categories:
    new_categories[category['category_id']] = category['name']

Coinpaprika

Defillama

import request
API_URL = "https://api.llama.fi"
url = f"{API_URL}/protocols"
r = request(url)
data = r.json()
protocols = {}
for protocol in data:
    protocols[protocol['slug']] = protocol['name']