api: log to a file
bot: add more debug logging
pagesInCategory: use debug mode