how to genrate graphs and diagrams from a wix database

I want to generate graphs and diagrams from wix database which changes atomatically when the database have new inputs . How to dothat in Wix. Do I need external API for this?
And also , How to get the count of inouts in a field of a database?

See here;
https://www.wix.com/corvid/example/create-a-custom-chart