Skip to content

Instantly share code, notes, and snippets.

@marks
Created August 31, 2010 03:14
Show Gist options
  • Select an option

  • Save marks/558486 to your computer and use it in GitHub Desktop.

Select an option

Save marks/558486 to your computer and use it in GitHub Desktop.
answer()
ask("Welcome to the Tropo company directory. Who are you trying to reach?", [
choices: "department(support, engineering, sales), person(jose, jason, adam)",
onChoice: { event->
switch(event.value) {
case "department":
log("Department info: $event.choice.interpretation")
break
case "person":
log("Person info: $event.choice.interpretation")
break
}
}
])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment