Convert JSONC to MSGPACK

Turn JSONC files into MessagePack. The same structure and key order in MessagePack, with integers, floats, booleans, null, text, lists and maps keeping their types and dates as text.

Converted in an isolated sandbox on our serversDeleted after 24 hours

Drop JSONC files on the dialor turn it to pick what to do

JSONC becomes compact MessagePack.The structure and key order carry over. Comments and trailing commas do not.

  1. What you get

    One MessagePack file with the same structure as your JSONC file. Keys stay in the order they appear in the source.

    Each value keeps its type. Integers, floats, booleans, null, text, lists and maps stay what they are, and none of them turns into text.

  2. What changes

    Comments are dropped. Trailing commas are dropped as well. Neither appears in the MessagePack file.

    Dates become text. A date in your file is written as a text value, not as a special date type.

  3. Going back

    To turn a MessagePack file into JSON with Comments again, use MSGPACK to JSONC. Comments removed in this conversion are not part of the MessagePack file, so they cannot come back that way.

JSONC and MSGPACK.What each format is.

The formats

From · JSONC

JSON with Comments

JSON that allows comments, as in editor and TypeScript configuration files.

Extensions
.jsonc
MIME type
text/x-jsonc
Kind
Text and data
To · MSGPACK

MessagePack

Binary JSON: the same values as JSON in a compact byte encoding.

Extensions
.msgpack .mpk
MIME type
application/msgpack
Kind
Text and data

In your code.The same JSONC to MSGPACK conversion through the API, for your app or your agent.

terminal
$ cv convert report.jsonc report.msgpack
$ cv convert report.jsonc report.msgpack

Questions.What people ask about JSONC to MSGPACK.

01OF 04

Yes. The keys stay in the same order as in the JSONC file.

They are dropped. The MessagePack file holds the data only.

Yes. Integers and floats keep their types. Booleans and null do too.

Dates are kept as text.

More conversions.Other ways in and out of JSONC and MSGPACK.