#!/bin/bash
echo '{"foo":{"bar":"X","baz":"Y"},"hello":{"abc":"A"}}' > config.json
jq . config.json
jq '.hello += {"def": "B"}' config.json > config.json.tmp
mv config.json.tmp config.json
jq . config.json
To embed this program on your website, copy the following code and paste it into your website's HTML: