I am attempting to use ScriptRunner to make a REST api call.
However, I am not certain that I have the syntax correct or where I can test to see if I am getting the data I am looking for.
This is the script I am working with :
import groovyx.net.http.*
import groovyx.net.http.ContentType.*
import groovyx.net.http.Method.*
import net.sf.json.*
def http = new HTTPBuilder('https://api.somewebsite.com')
http.get( path : '/MyPath/GoesHere/',
contentType : JSON,
query : [
token: 'MyToken',
license:'ABC123'] )
{ resp, reader -> println "response status: ${resp}"
println 'Response data: -----' }