Skip to content

v5.2.0 | Application emoji and premium buttons

Latest
Compare
Choose a tag to compare
@MinnDevelopment MinnDevelopment released this 03 Nov 16:35
· 6 commits to master since this release
26e1ea2

Overview

This release adds some new features for applications. We've also started working on more compliance tests to make contributing and reviewing changes easier.

Premium Buttons (#2752)

The interaction response replyWithPremiumRequired is being phased out in favor of custom messages with a new button style Button.premium(sku) to upsell specific premium features instead.

You can change your code to a simple reply(content) with this button as a component.

event.reply("This feature is only available for premium users.")
  .addActionRow(Button.primary(SkuSnowflake.fromId(PREMIUM_FEATURE_SKU)))
  .setEphemeral(true)
  .queue();

For more info, see the official Discord Changelog.

Application Emoji (#2726)

Your bot can now manage emoji with JDA by using JDA#createApplicationEmoji. These emojis can then be used like any other emoji with Emoji.fromCustom(name, id, animated).

New Features

Bug Fixes

Changes

  • Deprecated GatewayIntent#GUILD_EMOJIS_AND_STICKERS in favor of GUILD_EXPRESSIONS by @freya022 in #2755
  • Remove deprecated permission constants
  • Remove deprecated and stage instance privacy level

Full Changelog: v5.1.2...v5.2.0

Installation

Gradle

repositories {
    mavenCentral()
}
dependencies {
    implementation("net.dv8tion:JDA:5.2.0")
}

Maven

<dependency>
    <groupId>net.dv8tion</groupId>
    <artifactId>JDA</artifactId>
    <version>5.2.0</version> 
</dependency>