How to create and add info to a .json file

I want to people to be able to create their own databases in .json format. For that, I need to know how to create and modify .json files through the app.