Module chewdata::document::json

source ·
Expand description

Read and Write in JSON format.

Configuration

keyaliasDescriptionDefault ValuePossible Values
type-Required in order to use this document.jsonjson
metadatametaMetadata describe the resource.nullcrate::Metadata
is_pretty-Display json data readable for human.falsefalse / true
entry_path-Use this field if you want target a specific field in the json object.nullString in json pointer format

Examples:

[
    {
        "type": "read",
        "document": {
            "type": "json",
            "entry_path": "/0"
        }
    },
    {
        "type": "write",
        "document": {
            "type": "json",
            "is_pretty": true
        }
    }
]

input:

[
    {"field1":"value1"},
    {"field1":"value2"},
    ...
]

output:

[
    {
        "field1":"value1"
    }
]

Structs