title: JSON in Groovy / Grails
body: <p>I'm trying to access a site via their JSON export.</p>
  
  <p>The URL is: <a href="http://neotest.dabbledb.com/publish/neotest/f820728c-4451-41f6-b346-8cba54e52c6f/projects.jsonp" rel="nofollow noreferrer">http://neotest.dabbledb.com/publish/neotest/f820728c-4451-41f6-b346-8cba54e52c6f/projects.jsonp</a></p>
  
  <p>I'm using HTTPBuilder to try and accomplish this in Groovy, but am having trouble. I used the example code from <a href="http://groovy.codehaus.org/HTTP+Builder" rel="nofollow noreferrer">http://groovy.codehaus.org/HTTP+Builder</a> to come up with this:</p>
  
  <pre><code>// perform a GET request, expecting JSON response data
  http.request( GET, JSON ) {
      url.path = 'publish/neotest/f820728c-4451-41f6-b346-8cba54e52c6f/projects.jsonp'
  
      // response handler for a success response code:
      response.success = { resp, json -&gt;
          println resp.statusLine
  
          // parse the JSON response object:
          json.responseData.results.each {
              println "  ${it.titleNoFormatting} : ${it.visibleUrl}"
          }
      }
  }
  </code></pre>
  
  <p>However, when I run the unit test for the method I simply get <code>No such property: GET for class: ProjectController groovy.lang.MissingPropertyException: No such property: GET for class: ProjectController</code> which I'm having trouble understanding.</p>