James Clapper, the former Director of National Intelligence who has clashed with President Donald Trump, has a book deal.