
As a system administrator, you will often need to get information about the health and performance of your systems, using only whatever tools are available. Monitis, and its REST API, give you the utmost in flexibility, allowing you to use whatever tools you have, on any system. In this article, we’ll take a look at how AppleScript can be used to invoke REST API calls, using a system load monitor as an example.
Getting Started
To begin, you should read some of the previous articles discussing monitoring Linux or OS X with bash scripts. There are details of using the API covered there that we won’t cover again in this article. At a minimum, you should have your API key and secret key handy.
AppleScript is a language and programming environment used in OS X to automate tasks that need to interact with applications. For a system administrator with a UNIX background, using shell scripts will usually be the first choice, but AppleScript offers the ability to take advantage of special interfaces built into many OS X applications. It can also use the output of any UNIX command line programs. For this example, we’ll just use system load averages to illustrate the concept.
Read the full post