add optional count to stat functions
one count too many
enable cors to pass data to the frontend avoiding crsf