diff --git a/src/main/java/com/whatsapp/api/domain/messages/response/Contact.java b/src/main/java/com/whatsapp/api/domain/messages/response/Contact.java index 877e2b914..4c95f1e35 100644 --- a/src/main/java/com/whatsapp/api/domain/messages/response/Contact.java +++ b/src/main/java/com/whatsapp/api/domain/messages/response/Contact.java @@ -1,5 +1,6 @@ package com.whatsapp.api.domain.messages.response; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonProperty; @@ -7,6 +8,7 @@ * The type Contact. */ @JsonInclude(JsonInclude.Include.NON_NULL) +@JsonIgnoreProperties(ignoreUnknown = true) public record Contact( @JsonProperty("input") String input, diff --git a/src/main/java/com/whatsapp/api/domain/messages/response/Message.java b/src/main/java/com/whatsapp/api/domain/messages/response/Message.java index 1208cdde3..24d48bb03 100644 --- a/src/main/java/com/whatsapp/api/domain/messages/response/Message.java +++ b/src/main/java/com/whatsapp/api/domain/messages/response/Message.java @@ -1,5 +1,6 @@ package com.whatsapp.api.domain.messages.response; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonProperty; @@ -7,6 +8,7 @@ * The type Message. */ @JsonInclude(JsonInclude.Include.NON_NULL) +@JsonIgnoreProperties(ignoreUnknown = true) public record Message( @JsonProperty("id") String id) { diff --git a/src/main/java/com/whatsapp/api/domain/messages/response/MessageResponse.java b/src/main/java/com/whatsapp/api/domain/messages/response/MessageResponse.java index 78f2c5d72..03f375ce2 100644 --- a/src/main/java/com/whatsapp/api/domain/messages/response/MessageResponse.java +++ b/src/main/java/com/whatsapp/api/domain/messages/response/MessageResponse.java @@ -1,5 +1,6 @@ package com.whatsapp.api.domain.messages.response; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonProperty; @@ -9,6 +10,7 @@ * The type Message response. */ @JsonInclude(JsonInclude.Include.NON_NULL) +@JsonIgnoreProperties(ignoreUnknown = true) public record MessageResponse( @JsonProperty("messaging_product") String messagingProduct,