How can I return literal JSON from a node as a JSON object in views json? I have a content type with a field called output. This field will contain JSON. I want to output this field as JSON using Views JSON (in Views Datasource). The problem I'm encountering is views datasource is a. wrapping my field in quotes, and b. escaping my double quotes...

    [
    {
    "content": "{\"account-confirmation\":{\"body\":\"\",...


I need it to return something like:

    [
    {
    "content": {"account-confirmation":{"body":"",...


I've tried everything I could possibly think of. Is there any way I can output the literal value of the field without wrapping the value in quotes and escaping quotes?
Views Datasource will escape the contents of any string field. If the field were an object, it would be formatted as JSON. (See: views_datasource/views/plugins/views_plugin_style_json.inc.) There doesn't seem to be any way to override this behaviour other than patching the module or using some field type that would produce this result.

I faced a somewhat related problem and had to write my own API endpoint to get the JSON as I wanted it. I used views_get_view_result() to get the raw data and rework it so that I had the correct array structure. Then I run drupal_json_encode().