Using the API for reports & analytics