[#nlohmann-basic_json-0c-2constructor-0e8] = xref:nlohmann.adoc[nlohmann]::xref:nlohmann/basic_json-0c.adoc[basic_json]::basic_json :relfileprefix: ../../ :mrdocs: create a container (array or object) from an initializer list == Synopsis Declared in `<nlohmann/json.hpp>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- basic_json( xref:nlohmann/basic_json-0c/initializer_list_t.adoc[initializer_list_t] init, bool type_deduction = true, xref:nlohmann/basic_json-0c/value_t.adoc[value_t] manual_type = value_t::array); ---- == Parameters [cols="1,4"] |=== | Name| Description | *init* | initializer list with JSON values | *type_deduction* | whether to automatically deduce whether to create an array or an object from the initializer list _init_ | *manual_type* | the type to create when _type_deduction_ is `false` |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#