evaluate

fun evaluate(source: String, fileName: String = "<eval>"): JsValue

Parses and runs source. The answer is the last expression's value.