Advertisement
Guest User

Untitled

a guest
May 29th, 2023
54
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.70 KB | None | 0 0
  1. import json
  2. import requests
  3. pl = {
  4. "returnSecureToken": True,
  5. "email": "",
  6. "password": "",
  7. "clientType": "CLIENT_TYPE_WEB"
  8. }
  9.  
  10.  
  11. login = requests.post(url="https://identitytoolkit.googleapis.com/v1/accounts:signInWithPassword?key=[removed]", json = pl)
  12. login2 = login.json()
  13. data = requests.get(url="https://www.fishtank.live/api/leader-board", headers={"Authtoken": login2['idToken']})
  14. lb = data.json()
  15. total = 0.0
  16. print("\n")
  17. for user in lb['leaderBoard']:
  18. paypigAmount = user['tokens'] * (500/6400)
  19. print("\t{}: ${:.2f}".format(user['displayName'], paypigAmount))
  20. total += paypigAmount
  21. print("\n")
  22. print("\tTotal from top 30: ${:.2f}".format(total))
  23. print("\n")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement