Hi,
I would check out the client documentation. The action method has three examples that can be of help. The second two show how to handle the response of an object.
https://apidocs.mendix.com/7/client/mx.data.html
You can also check out some widgets on github. The custom string widget should be a good example. This will add text to a page based on the return value of a microflow (lines 70 – 93).
https://github.com/mendix/CustomString/blob/master/src/CustomString/widget/CustomString.js
Hope this helps!