#!/bin/bash

echo '{"foo":{"bar":"X","baz":"Y"},"hello":{"abc":"A"}}' > config.json
echo '{"hello":{"def":"B"}}' > config2.json

# merge using the * operator
jq -s '.[0] * .[1]' config.json config2.json

Embed on website

To embed this program on your website, copy the following code and paste it into your website's HTML: