diff --git a/src/main/java/discord4j/discordjson/json/AvatarDecorationData.java b/src/main/java/discord4j/discordjson/json/AvatarDecorationData.java new file mode 100644 index 00000000..ff2436db --- /dev/null +++ b/src/main/java/discord4j/discordjson/json/AvatarDecorationData.java @@ -0,0 +1,23 @@ +package discord4j.discordjson.json; + +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.databind.annotation.JsonDeserialize; +import com.fasterxml.jackson.databind.annotation.JsonSerialize; +import discord4j.discordjson.Id; +import org.immutables.value.Value; + +@Value.Immutable +@JsonSerialize(as = ImmutableAvatarDecorationData.class) +@JsonDeserialize(as = ImmutableAvatarDecorationData.class) +public interface AvatarDecorationData { + + static ImmutableAvatarDecorationData.Builder builder() { + return ImmutableAvatarDecorationData.builder(); + } + + String asset(); + + @JsonProperty("sku_id") + Id skuId(); + +} diff --git a/src/main/java/discord4j/discordjson/json/PartialMemberData.java b/src/main/java/discord4j/discordjson/json/PartialMemberData.java index 7a1f7c00..aaf1360b 100644 --- a/src/main/java/discord4j/discordjson/json/PartialMemberData.java +++ b/src/main/java/discord4j/discordjson/json/PartialMemberData.java @@ -42,6 +42,9 @@ static ImmutablePartialMemberData.Builder builder() { @JsonProperty("communication_disabled_until") Possible> communicationDisabledUntil(); + @JsonProperty("avatar_decoration_data") + Possible> avatarDecoration(); + default long flags() { return 0L; } diff --git a/src/main/java/discord4j/discordjson/json/ResolvedMemberData.java b/src/main/java/discord4j/discordjson/json/ResolvedMemberData.java index 4c53cd1f..77ed42ee 100644 --- a/src/main/java/discord4j/discordjson/json/ResolvedMemberData.java +++ b/src/main/java/discord4j/discordjson/json/ResolvedMemberData.java @@ -36,6 +36,9 @@ static ImmutableResolvedMemberData.Builder builder() { @JsonProperty("communication_disabled_until") Possible> communicationDisabledUntil(); + @JsonProperty("avatar_decoration_data") + Possible> avatarDecoration(); + default long flags() { return 0L; } diff --git a/src/main/java/discord4j/discordjson/json/UserData.java b/src/main/java/discord4j/discordjson/json/UserData.java index ef1930e7..9ab9b878 100644 --- a/src/main/java/discord4j/discordjson/json/UserData.java +++ b/src/main/java/discord4j/discordjson/json/UserData.java @@ -59,4 +59,7 @@ static ImmutableUserData.Builder builder() { @JsonProperty("public_flags") Possible publicFlags(); + + @JsonProperty("avatar_decoration_data") + Possible> avatarDecoration(); } diff --git a/src/main/java/discord4j/discordjson/json/gateway/GuildMemberUpdate.java b/src/main/java/discord4j/discordjson/json/gateway/GuildMemberUpdate.java index 69ff9f7a..92a6ead4 100644 --- a/src/main/java/discord4j/discordjson/json/gateway/GuildMemberUpdate.java +++ b/src/main/java/discord4j/discordjson/json/gateway/GuildMemberUpdate.java @@ -3,6 +3,7 @@ import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.databind.annotation.JsonDeserialize; import com.fasterxml.jackson.databind.annotation.JsonSerialize; +import discord4j.discordjson.json.AvatarDecorationData; import discord4j.discordjson.json.UserData; import discord4j.discordjson.Id; import discord4j.discordjson.possible.Possible; @@ -42,4 +43,7 @@ static ImmutableGuildMemberUpdate.Builder builder() { @JsonProperty("communication_disabled_until") Possible> communicationDisabledUntil(); + @JsonProperty("avatar_decoration_data") + Possible> avatarDecoration(); + }