changed endpoints for stats and messages