Question: gson how to create json?
Answer: Step 1 − Create Gson object using GsonBuilder. Create a Gson object. It is a reusable object. ... 
Step 2 − Deserialize JSON to Object. Use fromJson() method to get the Object from the JSON. ... 
Step 3 − Serialize Object to JSON. Use toJson() method to get the JSON string representation of an object.