I have below response. I know this is bad but sometimes we need to use this as requirements. With current update this extension can not make model for this but I have solution as when we have this type of response we do like this and Implement it if possible
@Keep
@JsonClass(generateAdapter = true)
data class test(
@Json(name = "test")
val name: Map<String, testModel>
)
@Keep
@JsonClass(generateAdapter = true)
data class testModel(
@Json(name = "amenities")
val amenities: List<Amenity?>?,
@Json(name = "bathroom")
val bathroom: Int?, // 3
@Json(name = "bedroom")
val bedroom: Int?, // 4
)
here we have used object name as key and object as model class so Please update it if possible. Don't take name as it is just demo
I have below response. I know this is bad but sometimes we need to use this as requirements. With current update this extension can not make model for this but I have solution as when we have this type of response we do like this and Implement it if possible
Actually I'm newbie so I don't know code as well as coding terms so If you don't understand anything read it with perspective of newbie.