Convert JSONL to XML
Turn JSONL files into XML. Objects become elements inside one root element and every value becomes text, with characters a tag name cannot hold turned into underscores.
Converted in an isolated sandbox on our serversDeleted after 24 hours
Drop JSONL files on the dialor turn it to pick what to do
JSON Lines turned into one XML file.Each object becomes an element inside a single root element.
What you get
One XML file. The objects from your JSONL file become elements inside one root element, and every value is written as text.
Keys that a tag name cannot hold are changed too: the characters that do not fit become underscores.
How keys and lists are written
A key that starts with @ becomes an attribute. When the value of such a key is a list or an object, it is written as JSON text. A key named #text becomes the element's own text.
A list repeats its element, once for each item. An empty list therefore disappears from the output, and a list of lists is flattened into one run of repeated elements.
When it stops
If the file could not be parsed, the conversion stops with
input_corrupted.
JSONL and XML.What each format is.
The formats
JSON Lines
JSON Lines, one JSON object per line, the format of logs and datasets.
- Extensions
- .jsonl .ndjson
- MIME type
- application
/jsonl - Kind
- Text and data
XML
XML documents and data.
- Extensions
- .xml
- MIME type
- application
/xml - Kind
- Text and data
In your code.The same JSONL to XML conversion through the API, for your app or your agent.
$ cv convert report.jsonl report.xml$ cv convert report.jsonl report.xmlQuestions.What people ask about JSONL to XML.
No. Every value becomes text.
The characters a tag name cannot hold are turned into underscores.
A list repeats its element once per item. With no items, nothing is written.
XML to JSONL converts in the other direction.