-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
157 additions
and
0 deletions.
There are no files selected for viewing
29 changes: 29 additions & 0 deletions
29
src/main/java/discord4j/discordjson/json/OnboardingData.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
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 java.util.List; | ||
import org.immutables.value.Value; | ||
|
||
@Value.Immutable | ||
@JsonSerialize(as = ImmutableOnboardingData.class) | ||
@JsonDeserialize(as = ImmutableOnboardingData.class) | ||
public interface OnboardingData { | ||
|
||
static ImmutableOnboardingData.Builder builder() { | ||
return ImmutableOnboardingData.builder(); | ||
} | ||
|
||
@JsonProperty("guild_id") | ||
Id guildId(); | ||
|
||
List<OnboardingPromptData> prompts(); | ||
|
||
@JsonProperty("default_channel_ids") | ||
List<Id> defaultChannelIds(); | ||
|
||
boolean enabled(); | ||
|
||
} |
35 changes: 35 additions & 0 deletions
35
src/main/java/discord4j/discordjson/json/OnboardingPromptData.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
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 java.util.List; | ||
import org.immutables.value.Value; | ||
|
||
@Value.Immutable | ||
@JsonSerialize(as = ImmutableOnboardingPromptData.class) | ||
@JsonDeserialize(as = ImmutableOnboardingPromptData.class) | ||
public interface OnboardingPromptData { | ||
|
||
static ImmutableOnboardingPromptData.Builder builder() { | ||
return ImmutableOnboardingPromptData.builder(); | ||
} | ||
|
||
Id id(); | ||
|
||
int type(); | ||
|
||
List<OnboardingPromptOptionData> options(); | ||
|
||
String title(); | ||
|
||
@JsonProperty("single_select") | ||
boolean singleSelect(); | ||
|
||
boolean required(); | ||
|
||
@JsonProperty("in_onboarding") | ||
boolean inOnboarding(); | ||
|
||
} |
34 changes: 34 additions & 0 deletions
34
src/main/java/discord4j/discordjson/json/OnboardingPromptOptionData.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
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 java.util.List; | ||
import java.util.Optional; | ||
import org.immutables.value.Value; | ||
|
||
@Value.Immutable | ||
@JsonSerialize(as = ImmutableOnboardingPromptOptionData.class) | ||
@JsonDeserialize(as = ImmutableOnboardingPromptOptionData.class) | ||
public interface OnboardingPromptOptionData { | ||
|
||
static ImmutableOnboardingPromptOptionData.Builder builder() { | ||
return ImmutableOnboardingPromptOptionData.builder(); | ||
} | ||
|
||
Id id(); | ||
|
||
@JsonProperty("channel_ids") | ||
List<Id> channelsIds(); | ||
|
||
@JsonProperty("role_ids") | ||
List<Id> rolesIds(); | ||
|
||
EmojiData emoji(); | ||
|
||
String title(); | ||
|
||
Optional<String> description(); | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
{ | ||
"guild_id": "960007075288915998", | ||
"prompts": [ | ||
{ | ||
"id": "1067461047608422473", | ||
"title": "What do you want to do in this community?", | ||
"options": [ | ||
{ | ||
"id": "1067461047608422476", | ||
"title": "Chat with Friends", | ||
"description": "", | ||
"emoji": { | ||
"id": "1070002302032826408", | ||
"name": "chat", | ||
"animated": false | ||
}, | ||
"role_ids": [], | ||
"channel_ids": [ | ||
"962007075288916001" | ||
] | ||
}, | ||
{ | ||
"id": "1070004843541954678", | ||
"title": "Get Gud", | ||
"description": "We have excellent teachers!", | ||
"emoji": { | ||
"id": null, | ||
"name": "😀", | ||
"animated": false | ||
}, | ||
"role_ids": [ | ||
"982014491980083211" | ||
], | ||
"channel_ids": [] | ||
} | ||
], | ||
"single_select": false, | ||
"required": false, | ||
"in_onboarding": true, | ||
"type": 0 | ||
} | ||
], | ||
"default_channel_ids": [ | ||
"998678771706110023", | ||
"998678693058719784", | ||
"1070008122577518632", | ||
"998678764340912138", | ||
"998678704446263309", | ||
"998678683592171602", | ||
"998678699715067986" | ||
], | ||
"enabled": true | ||
} |