Skip to content

Instantly share code, notes, and snippets.

@espeed
Created November 12, 2011 21:30
Show Gist options
  • Save espeed/1361147 to your computer and use it in GitHub Desktop.
Save espeed/1361147 to your computer and use it in GitHub Desktop.
Groovy JSON Example
#!/usr/bin/env groovy
import groovy.json.JsonSlurper
def slurper = new JsonSlurper()
def payload = '{"age": 34, "name": "james"}'
def data = slurper.parseText(payload)
println data
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment