I'm working with a timestamp that is formatted Thu, 04 Jan 2024 18:25:01 +0000 but I need it in Unix time. I've looked at several library functions and cannot figure out how I can achieve this. How can I convert this to a unix timestamp?
I looked at the different Python datetime methods and none of them would achieve my goal.
Use
datetime.timestampthat gives UNIX timestamp, in seconds, precision of microsecondsUse
datetime.strptimeto convert a string to adatetimeobject