Is there any API to read supply voltage of PSOC chip?
Welcome in the fascinating world of PSoCs!
There is no direct API, but you could use an ADC to measure it. Can you be a bit more specific what you want to do, what your problem is?
There are basically two methods:
The ADC-configuration using 6 * VRef is explicitely mentioned for measuring the supply-voltage.
Oh, I did forget about that ADC mode. Sure, that would be the easiest version.
When you setup A/D also make sure you set
input buffer to "bypass buffer" in order to get a
CM range that includes the rail (Vdda).