PostgreSQL Getting a unix time from a timstamp with time zone

If we have a timestamp with a timezone then getting the unix time from this is simple.
Note now() returns a timestamp with timezone so this query gets the current unix time

SELECT EXTRACT(epoch FROM now());