From ed76bb5ba8236ba6c4fdac62064cb29a258c3e3f Mon Sep 17 00:00:00 2001 From: Zhou Date: Sat, 30 Sep 2023 16:16:24 +0800 Subject: [PATCH 1/2] fix https://github.com/Bindambc/whatsapp-business-java-api/issues/125 --- .../com/whatsapp/api/domain/messages/response/Message.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) 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..df34ff517 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 @@ -8,6 +8,6 @@ */ @JsonInclude(JsonInclude.Include.NON_NULL) public record Message( - - @JsonProperty("id") String id) { + @JsonProperty("id") String id, + @JsonProperty("message_status") String messageStatus){ } From fc2c73c651c25481ffdddd4879a08e6f29c464e7 Mon Sep 17 00:00:00 2001 From: Zhou Wei Date: Mon, 16 Oct 2023 15:24:40 +0800 Subject: [PATCH 2/2] fix #127 --- src/main/java/com/whatsapp/api/domain/webhook/WebHook.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/whatsapp/api/domain/webhook/WebHook.java b/src/main/java/com/whatsapp/api/domain/webhook/WebHook.java index e2380c177..8c087e45f 100644 --- a/src/main/java/com/whatsapp/api/domain/webhook/WebHook.java +++ b/src/main/java/com/whatsapp/api/domain/webhook/WebHook.java @@ -1,6 +1,7 @@ package com.whatsapp.api.domain.webhook; import com.fasterxml.jackson.core.JsonProcessingException; +import com.fasterxml.jackson.databind.DeserializationFeature; import com.fasterxml.jackson.databind.ObjectMapper; /** @@ -8,7 +9,7 @@ * Use this class to deserialize webhook events */ public final class WebHook { - private static final ObjectMapper mapper = new ObjectMapper(); + private static final ObjectMapper mapper = new ObjectMapper().configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false); /** * Construct WebHookEvent object