{"id":13730374,"url":"https://github.com/taocpp/json","last_synced_at":"2025-05-15T08:05:17.540Z","repository":{"id":38250281,"uuid":"46943899","full_name":"taocpp/json","owner":"taocpp","description":"C++ header-only JSON library","archived":false,"fork":false,"pushed_at":"2025-03-11T16:50:21.000Z","size":6574,"stargazers_count":630,"open_issues_count":5,"forks_count":87,"subscribers_count":34,"default_branch":"main","last_synced_at":"2025-04-14T13:07:57.006Z","etag":null,"topics":["cbor","cpp","cpp17","header-only","jaxn","json","json-patch","json-pointer","json-schema","msgpack","ubjson"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/taocpp.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2015-11-26T19:34:08.000Z","updated_at":"2025-04-12T10:08:47.000Z","dependencies_parsed_at":"2023-11-16T16:03:36.936Z","dependency_job_id":"4d209937-57a5-4f67-8ff2-33d114036b47","html_url":"https://github.com/taocpp/json","commit_stats":{"total_commits":2175,"total_committers":17,"mean_commits":"127.94117647058823","dds":0.3094252873563218,"last_synced_commit":"3d1d4fc7c7aa89df155b10e2eaf585564e8e8b44"},"previous_names":[],"tags_count":14,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/taocpp%2Fjson","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/taocpp%2Fjson/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/taocpp%2Fjson/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/taocpp%2Fjson/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/taocpp","download_url":"https://codeload.github.com/taocpp/json/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254301426,"owners_count":22047902,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cbor","cpp","cpp17","header-only","jaxn","json","json-patch","json-pointer","json-schema","msgpack","ubjson"],"created_at":"2024-08-03T02:01:13.917Z","updated_at":"2025-05-15T08:05:17.462Z","avatar_url":"https://github.com/taocpp.png","language":"C++","readme":"# Welcome to taoJSON\n\n[![Windows CI](https://github.com/taocpp/json/workflows/Windows/badge.svg)](https://github.com/taocpp/json/actions?query=workflow%3AWindows)\n[![macOS CI](https://github.com/taocpp/json/workflows/macOS/badge.svg)](https://github.com/taocpp/json/actions?query=workflow%3AmacOS)\n[![Linux CI](https://github.com/taocpp/json/workflows/Linux/badge.svg)](https://github.com/taocpp/json/actions?query=workflow%3ALinux)\n[![Android CI](https://github.com/taocpp/json/workflows/Android/badge.svg)](https://github.com/taocpp/json/actions?query=workflow%3AAndroid)\n\u003cbr\u003e\n[![clang-analyze](https://github.com/taocpp/json/workflows/clang-analyze/badge.svg)](https://github.com/taocpp/json/actions?query=workflow%3Aclang-analyze)\n[![clang-tidy](https://github.com/taocpp/json/workflows/clang-tidy/badge.svg)](https://github.com/taocpp/json/actions?query=workflow%3Aclang-tidy)\n[![Sanitizer](https://github.com/taocpp/json/workflows/Sanitizer/badge.svg)](https://github.com/taocpp/json/actions?query=workflow%3ASanitizer)\n[![CodeQL](https://github.com/taocpp/json/workflows/CodeQL/badge.svg)](https://github.com/taocpp/json/actions?query=workflow%3ACodeQL)\n[![Code Coverage](https://codecov.io/gh/taocpp/json/branch/main/graph/badge.svg?token=ykWa8RRdyk)](https://codecov.io/gh/taocpp/json)\n\ntaoJSON is a C++ header-only JSON library that provides a generic [Value Class](doc/Value-Class.md), uses [Type Traits](doc/Type-Traits.md) to interoperate with C++ types, uses an [Events Interface](doc/Events-Interface.md) to convert from and to JSON, JAXN, CBOR, MsgPack and UBJSON, and much more...\n\n## Documentation\n\n* [Version 1.x](doc/README.md) (requires C++17)\n\n*Warning: The documentation is currently not quite keeping pace with what will hopefully be the last large pre-1.0.0 development burst.*\n\n## Contact\n\nFor questions and suggestions regarding taoJSON, success or failure stories, and any other kind of feedback, please feel free to open a [discussion](https://github.com/taocpp/json/discussions), an [issue](https://github.com/taocpp/json/issues) or a [pull request](https://github.com/taocpp/json/pulls) on GitHub or contact the authors at `taocpp(at)icemx.net`.\n\n## Features\n\n* Supported Standards\n\n  * [RFC8259], [ECMA-404]: The JavaScript Object Notation (JSON) Data Interchange Format.\n  * Achieves a **100%** conformance score in the [Native JSON Benchmark] tests.\n  * [RFC6901]: JavaScript Object Notation (JSON) Pointer.\n  * [RFC6902]: JavaScript Object Notation (JSON) Patch.\n  * [RFC7049]: Concise Binary Object Representation ([CBOR]).\n  * [JAXN]: Relaxed JSON.\n  * [MsgPack]: MessagePack binary format (without extensions).\n  * [UBJSON]: Universal Binary JSON.\n\n* [Value Class](doc/Value-Class.md)\n\n  * JSON data model extended with non-finite number values and binary data.\n  * Construction of objects and arrays via `std::initializer_list`.\n  * Conversion from and to arbitrary *user-defined types* via [Type Traits](doc/Type-Traits.md).\n  * Built around STL containers `std::variant`, `std::string`, `std::map`, `std::vector`, etc.\n  * No memory allocations by the Value class itself (the wrapped containers allocate normally).\n  * Instance sharing for string, binary, Value, and *user-defined types* via non-owning pointers.\n  * C++11 literal operator for Values, including binary data.\n  * Optional [Base class for Values](doc/Advanced-Use-Cases.md#custom-base-class-for-values) (e.g. to [annotate (sub-)values with file and line](doc/Advanced-Use-Cases.md#annotate-with-filename-and-line-number)).\n\n* [Events Interface](doc/Events-Interface.md)\n\n  * Simple, straightforward and flexible Events API.\n  * Events-to-Value and Value-to-Events interfaces.\n  * Parse JSON \u0026 JAXN string representation to Events.\n  * Stream Events to (prettified) JSON \u0026 JAXN string representation.\n  * Conversion from and to binary formats, currently [CBOR], [UBJSON], [MsgPack].\n  * Conversion from and to *other* JSON libraries (e.g. [`contrib/nlohmann.cpp`](contrib/nlohmann.cpp)).\n  * Events comparison, hashing, counting, and schema validation.\n  * Events Transformers to manipulate Events on-the-fly.\n\n## Status\n\nThe library is stable as in \"works correctly\" over months of multiple real-world applications.\n\nThe library is not stable as in \"under construction\"; some parts of the API are under discussion and development and might change and/or be extended before version 1.0.\n\nThis library also serves as a real-world example application of the [Parsing Expression Grammar Template Library (PEGTL)], which is used for parsing the JSON and JAXN representation formats.\n\n## Package Managers\n\nYou can download and install taoJSON using the [Conan](https://github.com/conan-io/conan) package manager:\n\n    conan install taocpp-json/1.0.0-beta.11@\n\nThe taocpp-json package in conan is kept up to date by Conan team members and community contributors.\nIf the version is out-of-date, please [create an issue or pull request](https://github.com/conan-io/conan-center-index) on the Conan Center Index repository.\n\n## Thank You\n\n* Niels Lohmann and his [JSON library](https://github.com/nlohmann/json) for the inspiration.\n* Milo Yip and his [Native JSON Benchmark] for a reference to measure progress against.\n\n## The Art of C++\n\ntaoJSON is part of [The Art of C++](https://taocpp.github.io/).\n\n[\u003cimg alt=\"colinh\" src=\"https://avatars.githubusercontent.com/u/113184\" width=\"120\"\u003e](https://github.com/colinh)\n[\u003cimg alt=\"d-frey\" src=\"https://avatars.githubusercontent.com/u/3956325\" width=\"120\"\u003e](https://github.com/d-frey)\n[\u003cimg alt=\"uilianries\" src=\"https://avatars.githubusercontent.com/u/4870173\" width=\"120\"\u003e](https://github.com/uilianries)\n\n## License\n\n\u003ca href=\"https://opensource.org/licenses/MIT\"\u003e\u003cimg align=\"right\" src=\"https://opensource.org/wp-content/uploads/2009/06/OSIApproved.svg\" width=\"150\" hspace=\"20\" alt=\"Open Source Initiative\"\u003e\u003c/a\u003e\n\ntaoJSON is certified [Open Source] software.\nIt may be used for any purpose, including commercial purposes, at absolutely no cost.\nIt is distributed under the terms of the [MIT license] reproduced here.\n\n\u003e Copyright (c) 2015-2023 Dr. Colin Hirsch and Daniel Frey\n\u003e\n\u003e Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:\n\u003e\n\u003e The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n\u003e\n\u003e THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n\n## Additional Licenses\n\ntaoJSON contains modified portions of the [double-conversion library](https://github.com/google/double-conversion) which is licensed as follows:\n\n\u003e Copyright 2006-2011, the V8 project authors. All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:\n\u003e\n\u003e * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.\n\u003e * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.\n\u003e * Neither the name of Google Inc. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.\n\u003e\n\u003e THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n\ntaoJSON contains modified portions of [James Edward Anhalt III's itoa library](https://github.com/jeaiii/itoa) which is licensed as follows:\n\n\u003e Copyright (c) 2017 James Edward Anhalt III - https://github.com/jeaiii/itoa\n\u003e\n\u003e Permission is hereby granted, free of charge, to any person obtaining a copy\n\u003e of this software and associated documentation files (the \"Software\"), to deal\n\u003e in the Software without restriction, including without limitation the rights\n\u003e to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n\u003e copies of the Software, and to permit persons to whom the Software is\n\u003e furnished to do so, subject to the following conditions:\n\u003e\n\u003e The above copyright notice and this permission notice shall be included in all\n\u003e copies or substantial portions of the Software.\n\u003e\n\u003e THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n\u003e IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n\u003e FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n\u003e AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n\u003e LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n\u003e OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\n\u003e SOFTWARE.\n\ntaoJSON contains modified portions of [Ulf Adams' Ryu implementation](https://github.com/ulfjack/ryu) which is licensed as follows:\n\n\u003e Copyright 2018 Ulf Adams\n\u003e\n\u003e The contents of this file may be used under the terms of the Apache License, Version 2.0.\n\u003e\n\u003e    (See accompanying file LICENSE.ryu or copy at\n\u003e     http://www.apache.org/licenses/LICENSE-2.0)\n\u003e\n\u003e Alternatively, the contents of this file may be used under the terms of the Boost Software License, Version 1.0.\n\u003e    (See accompanying file LICENSE-Boost or copy at\n\u003e     https://www.boost.org/LICENSE_1_0.txt)\n\u003e\n\u003e Unless required by applicable law or agreed to in writing, this software is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n\n[CBOR]: http://cbor.io\n[ECMA-404]: http://www.ecma-international.org/publications/standards/Ecma-404.htm\n[JAXN]: https://github.com/stand-art/jaxn\n[JSON Reference]: https://tools.ietf.org/html/draft-pbryan-zyp-json-ref-03\n[JSON Schema]: http://json-schema.org/documentation.html\n[MsgPack]: http://msgpack.org\n[MIT license]: http://www.opensource.org/licenses/mit-license.html\n[Native JSON Benchmark]: https://github.com/miloyip/nativejson-benchmark\n[Open Source]: http://www.opensource.org/docs/definition.html\n[Parsing Expression Grammar Template Library (PEGTL)]: https://github.com/taocpp/PEGTL\n[RFC6901]: https://tools.ietf.org/html/rfc6901\n[RFC6902]: https://tools.ietf.org/html/rfc6902\n[RFC7049]: https://tools.ietf.org/html/rfc7049\n[RFC8259]: https://tools.ietf.org/html/rfc8259\n[UBJSON]: http://ubjson.org\n","funding_links":[],"categories":["JSON","C++","进程间通信","Data Formats"],"sub_categories":["Json"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftaocpp%2Fjson","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftaocpp%2Fjson","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftaocpp%2Fjson/lists"}