The release of FileMaker 16 includes an interesting new function used to create a JSON object called JSONSetElement.
You can see how it works here. Download the simple sample file to create one single JSON object with all relevant information, including key-value pairs, arrays, nested objects for the contact record, and more.