Chook is a Ruby module that provides both a web server for handling WebHook events sent from Jamf Pro, as well as a testing framework for using Ruby to send simulated events to a webhook handler.
When used as a handler for events from Jamf Pro, no Ruby coding is necessary - handling scripts can be written in any language and the JSON version of the webhook event will be passed to the script directly. If you are a Ruby coder, handlers can be written using the Chook module and event objects themselves and will run internally as threads of the server process iteself.
Event testing with Ruby is possible by instantiating TestEvent classes with randomized data or data from your live Jamf Pro environment. These test event objects can then be sent to any webhook handling server.
New in version 1.1.0:
For details about the new features, please see the documentation link.
- Now requires 'thin' as the server engine.
- Supports SSL and HTTP Basic Authentication
- Server logging is now a thing, with access to logging from both internal and external handlers
- A simple admin interface is available by pointing your browser at the chook server
- Internal handlers are now stored as anonymous objects rather than Procs, and the handler code block is stored as an instance method on the object. This means that either 'break' or 'return' will work to exit a handler.
- Other bugfixes and improvements.