Connecting to Alexa with FAUXMOESP library not detecting the device
If you are using fauxmoESP library version 3.0 and above your device will not be detected by alexa, i dont know why this is.
You may degrade fauxmoESp version to 2.4.0 so that your issue ie. .onSetState will be resolved.

Are you able to connect wifi?