I'm doing exactly this in my libGDX game. You do it like this:
{
"object_name": "basic_left_gun",
"object_type" : "player_ship_component",
"object_subtype" : "player_ship_left_weapon",
"subtype_properties" :
{
"shot_name" : "basic_shot"
},
"is_animated": false,
"is_dual_state": false,
"is_destructible": true,
"hitpoints": 16,
"second_state_name": "",
}
So have a look at the "subtype_properties" field. It has another JSON object inside of it. So when I serialize and query the JSON object in java, when I do json.get("subtype_properties"), I actually just get another JSON object. From there I can query and get the attributes.
Theoretically, you could do this forever and ever. Although my approach has been to have basic definitions stores in JSONs for each object, and then link their properties together using the nested JSON objects as above, or define unique properties using the same approach.