def get_request(): r = requests.get(url) return r def second_func(): value = get_request(url) # do smth with the value # How to pass other arguments from requests.get such as params=..., headers=... (maybe as **kwargs) to get_request() in the second function