Skip to content

Commit

Permalink
Merge #162 into 1.7.8
Browse files Browse the repository at this point in the history
  • Loading branch information
Azn9 committed Mar 27, 2024
2 parents a3fc6c3 + 0fb0ab5 commit fd84d1b
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,11 @@ static ImmutableApplicationCommandData.Builder builder() {

/**
* whether the command is enabled in DM by default when the app is added globally (default to true)
*
* @deprecated use {@link #contexts()} instead
*/
@JsonProperty("dm_permission")
@Deprecated
Possible<Boolean> dmPermission();

/**
Expand All @@ -86,4 +89,10 @@ static ImmutableApplicationCommandData.Builder builder() {
*/
@JsonProperty("default_member_permissions")
Optional<String> defaultMemberPermissions();

@JsonProperty("integration_types")
List<Integer> integrationTypes();

@JsonProperty("contexts")
List<Integer> contexts();
}
Original file line number Diff line number Diff line change
Expand Up @@ -59,4 +59,10 @@ static ImmutableApplicationCommandRequest.Builder builder() {
* value of ApplicationCommandType (defaults to 1, CHAT_INPUT)
*/
Possible<Integer> type();

@JsonProperty("integration_types")
Possible<List<Integer>> integrationTypes();

@JsonProperty("contexts")
Possible<List<Integer>> contexts();
}
6 changes: 6 additions & 0 deletions src/main/java/discord4j/discordjson/json/InteractionData.java
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
import org.immutables.value.Value;

import java.util.List;
import java.util.Map;

@Value.Immutable
@JsonSerialize(as = ImmutableInteractionData.class)
Expand Down Expand Up @@ -69,4 +70,9 @@ static ImmutableInteractionData.Builder builder() {

@JsonProperty("entitlements")
List<EntitlementData> entitlements();

@JsonProperty("authorizing_integration_owners")
Map<Integer, String> authorizingIntegrationOwners();

Possible<Integer> context();
}

0 comments on commit fd84d1b

Please sign in to comment.