Foreign Secretary David Lammy has said 'we may well be on the brink' of a ceasefire deal between Israel and Hamas.