you probably don't want to use CGEvents for Cocoa implementation.
Instead you might want to try
NSEvent API.
There are two constructors you need to utilize: keyEventWithType... and mouseEventWithType...
These two should be enough to synthesize input for keyboard and mouse respectivly.
I think Tom left the community quite awhile ago (over 10 years ago). So, you might not hear back from him any time soon. Would you like to become the new maintainer?