Are you API about ServiceDesk Plus - Part 1?

Are you API about ServiceDesk Plus - Part 1?

The REST API in ServiceDesk Plus is a very powerful integration tool. However, the information available about how to use the API interface can be a little confusing for non programmers. Hopefully the following will help the uninitiated amongst us.

Some terminology first ... REST stands for  Re presentational  S tate  Tr ansfer. (It is sometimes spelled "ReST".) It relies on a stateless, client-server, cacheable communications protocol and, importantly for us, in virtually all cases uses the HTTP protocol. Basically we can make HTTP calls via a URL and 'talk' to ServiceDesk and get it to do things!

ServiceDesk Plus has a very useful interactive documentation tool in the Admin tab that provides a starting point for understanding and testing the REST API interface:









Clicking on the Documentation button takes you to a list of functions that are available for the various modules in ServiceDesk Plus. In the example below we've chosen to 'View Request details' and the interactive documentation is expecting a valid Request ID to process the REST API request:












By entering a valid Request ID of a current request in your ServiceDesk Plus and pressing the 'Try Now' button you should see details of the Request URL used and information in the Response Body on the right of the screen:













The data in the Response Body is basically being returned, in this utility, as a JSON string. JSON stands for JavaScript Object Notation and is a lightweight data-exchange format. In practical terms we have a formatted data response that we can use and interpret with a script or programme. As you can see the output is relatively easy to read and understand even as the JSON output. 

It's worth noting that we can also use JSON to send a collection of data to the REST API. If you look at the option to 'Add new request' you will see an example of this (yes this will create a new request in ServiceDesk Plus) :




















For completeness there are various operations that can be performed by a REST API interface. In our example, and for most API operations, a POST HTTP Request Method is used. However, you will find examples of GETPUT and DELETE operations as well. We just need to make sure we identify the operation being performed in any script or programme calling the REST API in ServiceDesk Plus.

Hopefully the documentation will give you an insight into potentially how powerful the REST API really is. In Part 2 we'll look at the mechanics and configuration required to actually do this for real.

                New to ADManager Plus?

                  New to ADSelfService Plus?