webserver: determine daemon_type by product type
api: share apiServer* code across auth, recursor

Gives us "free" implementations of /servers, /servers/localhost,
/servers/localhost/{config, search-log, statistics} for the recursor.

Move JSON helper functions from ws-auth.cc to json.cc; turn
parseJsonBody into HttpRequest::json().