> For the complete documentation index, see [llms.txt](https://sevenval.gitbook.io/flat/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://sevenval.gitbook.io/flat/reference/functions/json-doc.md).

# json-doc()

```
node-set json-doc(string path)
```

converts the JSON document at the given `path` into [OXN](/flat/reference/templating/oxn.md), parses it and returns the `<json>` *root element*.

Relative paths are resolved relative to the flow file's path.

`user.json`:

```javascript
{
  "name": "brenda"
}
```

```
json-doc("user.json")/name
```

## Example: Read a JSON config

Flow:

```markup
<flow>
  <echo if="json-doc('fit://site/conf.json')/maintenance" status="503">
    Under maintenance
  </echo>
</flow>
```
