Depending on whether there may be multiple items in the config json file, I would do something like the following (general):
<load config>
for item in config:
if item['domain'] == 'test.com':
<do something>
else:
<do something else>
If you know there will only ever be one item in the config, then you could take the option listed in the comment, and test for:
if config[0]['domain'] == 'test.com': <...>
instead.
Note that this simple example is only valid if your JSON input was created under your control - e.g. written by another module of your application or etc. In other words, it will fail if item['domain'] is (say) 'TEST.com' - so you may need to do some cleanup on the input before testing.
Quick example in Python REPL:
>>> li
[{'domain': 'test.com'}, {'domain': 'test1.com'}]
>>> for item in li:
... if item['domain'] == 'test.com':
... print('test.com')
... else:
... print('other')
...
test.com
other