daily pastebin goal
7%
SHARE
TWEET

Untitled

a guest Mar 22nd, 2019 56 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. import requests
  2. from sys import argv
  3.  
  4. BASE_URL = 'hui://pizda.jigurda/get/{}'
  5.  
  6. def parse_path(json, *path):
  7.     for k in path:
  8.         json = json[k]
  9.     return json
  10.  
  11. def req(url_param, path):
  12.     response = requests.request("GET",
  13.                                 BASE_URL.format(url_param),
  14.                                 headers=headers,
  15.                                 cookies=jar,
  16.                                 verify=False)
  17.     rval = response.json()
  18.     return parse_path(rval, path)
  19.  
  20. if __name__ == '__main__':
  21.     print(req(argv[1], argv[2].split('/')))
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top