In MacOS, it is really convoluted. Do I dynamically load some bundle? What bundle? Likely they'll put it somewhere else sometime soon.
Of course in principle, there is some API but the way that Apple treats them is very different.
For example, I want to get how many fingers are touching the trackpad right now and the current position of these touches. There are all sorts of things like PinchControllers that need to be initialized and they emit events etc., but nothing to give you the current state of affairs or exactly what you want.