[SPARK] Add dedicated API for returning results as raw JSON

Relates to #251