pg_replication_slots: how to determine how far behind a consumer is?
The view you are looking for is pg_stat_replication.  In 9.6 you can only get this info expressed in LSN, not clock time.  Starting in v10, you can get it in clock time.