diff --git a/telegrambots-meta/src/main/java/org/telegram/telegrambots/meta/api/objects/chatmember/ChatMemberUnknown.java b/telegrambots-meta/src/main/java/org/telegram/telegrambots/meta/api/objects/chatmember/ChatMemberUnknown.java new file mode 100644 index 00000000..208708fd --- /dev/null +++ b/telegrambots-meta/src/main/java/org/telegram/telegrambots/meta/api/objects/chatmember/ChatMemberUnknown.java @@ -0,0 +1,44 @@ +package org.telegram.telegrambots.meta.api.objects.chatmember; + +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.databind.annotation.JsonDeserialize; +import lombok.AllArgsConstructor; +import lombok.Builder; +import lombok.EqualsAndHashCode; +import lombok.Getter; +import lombok.NoArgsConstructor; +import lombok.Setter; +import lombok.ToString; +import org.telegram.telegrambots.meta.api.objects.User; + +/** + * @author Ruben Bermudez + * @version 5.3 + * + * Represents a chat member that has no additional privileges or restrictions, it's unknown if the member is still inside the group. + */ +@JsonDeserialize +@EqualsAndHashCode(callSuper = false) +@Getter +@Setter +@ToString +@NoArgsConstructor +@AllArgsConstructor +@Builder +public class ChatMemberUnknown implements ChatMember { + public static final String STATUS = "unknown"; + + private static final String STATUS_FIELD = "status"; + private static final String USER_FIELD = "user"; + + /** + * The member's status in the chat, always “unknown” + */ + @JsonProperty(STATUS_FIELD) + private final String status = STATUS; + /** + * Information about the user + */ + @JsonProperty(USER_FIELD) + private User user; +}