It is necessary to automate the receipt of the token, there is a link that I am sending, and I get a new one that contains the token. How to do it on python?

r = requests.get(link) print(r) print(r.url) 

I found such and similar methods on the Internet, but they return the link before the redirect.

  • Are you sure that the word "redirect" in your case? If so, show what you want with the example of httpbin.org/#/Redirects - jfs
  • the point is that I manually insert the url into the address bar of the browser, after which I get a new url, and I need to do it programmatically, I apologize for not knowing the terminology. - Lonely_bassist 2:26 pm
  • Give a specific example of input output. Suppose you have an initial url httpbin.org/absolute-redirect/3 Which of several intermediate links would you like to receive? Only the last? - jfs

0