JSON.stringify(yourJSONObject) //Encode your object into a string JSON.parse(yourJSONString) //Decode your JSON String into an Object
new global.JSON().encode(yourJSONObject); //Encode your object into a String new global.JSON().decode(yourJSONString); //Decode your JSON String into an Object
One nice thing about using REST in ServiceNow is that they provide a number of APIs (Table API, Aggregate, Import Set, Performance Analytics) based upon what type of integration is needed.
An additional nice feature that came in the Fuji release was the “REST API Explorer” which allows you to easily test the different REST methods with different data.
A similar tool that can be used externally to test can be found at http://hurl.it
Here are some more links to help you along your REST journey: