Implement the meta/stats API endpoint.

As a pre-req, also implement the first stats hook (archive-download).