Questions tagged [moshi]

Moshi is a top-notch JSON library designed specifically for Android and Java developers, seamlessly allowing the conversion of JSON data into Java objects.

The deserialization of 0 and 1 to "Boolean?" failed in Moshi

When attempting to deserialize a JSON field with values of 0, 1, or null into a "Boolean?" data type, the following custom Annotation is used: @Retention(AnnotationRetention.RUNTIME) @JsonQualifier annotation class BooleanType class BooleanAdapter { @ ...

Working with JSON Strings using moshi and retrofit2

The API I am currently utilizing responds with a JSON object nested inside a list structure: [ { "name": "Seattle", "lat": 47.6038321, "lon": -122.3300624, "country": &qu ...