I got a similar request to write a book for Packt. They offered almost zero money upfront, and when asked could offer zero reasons as to why they thought there was a market for this book.
It really seemed their plan was "James takes almost all the risk and does almost all of the work but James does not get almost all the money."