from dhooks import Webhook
import secrets
from pycoingecko import CoinGeckoAPI
hook = Webhook('https://discordapp.com/api/webhooks/780514501883723786'
'/pXD1dh_YFdfMpJO7KtwQsb0GepPWwP53qv20Nt56eFeObg7HhcQfGSkbsi06tDhMKPdi')
def hello_world():
hook.send("Hello World!")
def get_hive_price():
cg = CoinGeckoAPI()
hive_prices = cg.get_price("hive", "ltc,btc,eos,doge,bch,cad,usd")
prices = hive_prices["hive"]
hive_btc = round(prices["btc"], 10)
output = "{:.10f}".format(hive_btc)
hook.send(f"""HIVE PRICES:\n${prices["usd"]} USD\n${prices["cad"]} CAD\n{output} BTC""")
def roll(a):
rand_below = secrets.randbelow(a)
hook.send(f"""Max: {a}\nRoll: {rand_below}""")
hello_world()
get_hive_price()
roll(100)