Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds docs for Onboarding updates and new mode field #6101

Merged
merged 4 commits into from
Jul 13, 2023
Merged

Conversation

hammerdr
Copy link
Contributor

No description provided.

@@ -1272,6 +1280,19 @@ Modify the guild's [Welcome Screen](#DOCS_RESOURCES_GUILD/welcome-screen-object)

Returns the [Onboarding](#DOCS_RESOURCES_GUILD/guild-onboarding-object) object for the guild.

## Modify Guild Onboarding % PUT /guilds/{guild.id#DOCS_RESOURCES_GUILD/guild-object}/onboarding
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems to allow the X-Audit-Log-Reason header

Comment on lines +1299 to +1302
| prompts | array of [onboarding prompt](#DOCS_RESOURCES_GUILD/guild-onboarding-object-onboarding-prompt-structure) objects | Prompts shown during onboarding and in customize community |
| default_channel_ids | array of snowflakes | Channel IDs that members get opted into automatically |
| enabled | boolean | Whether onboarding is enabled in the guild |
| mode | [onboarding mode](#DOCS_RESOURCES_GUILD/guild-onboarding-object-onboarding-mode) | Current mode of onboarding |
Copy link
Contributor

@jaw0r3k jaw0r3k Apr 21, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you add a note that all params are optional?


| Field | Type | Description |
| ------------------- | --------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------- |
| prompts | array of [onboarding prompt](#DOCS_RESOURCES_GUILD/guild-onboarding-object-onboarding-prompt-structure) objects | Prompts shown during onboarding and in customize community |
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the Onboarding Prompt Structure contains an id, is it required to be included?

@lumap
Copy link

lumap commented May 5, 2023

Suggestion: add the following error code to docs/topics/Opcodes_and_Status_Codes.md as part of this PR:

| 350001 | Cannot update onboarding while below requirements                                                                             |

Occurs when one of the requirements (number of default channels for example) isn't met anymore and a bot/user tries to edit any part of onboarding

docs/resources/Guild.md Outdated Show resolved Hide resolved
DonovanDMC added a commit to OceanicJS/Oceanic that referenced this pull request May 27, 2023
Co-authored-by: shay <swdewael@gmail.com>
@hammerdr hammerdr requested a review from shaydewael June 12, 2023 19:00
@gamer415
Copy link

gamer415 commented Jul 1, 2023

Thanks

@gamer415
Copy link

gamer415 commented Jul 1, 2023

Thanks 😀😊

@shaydewael shaydewael merged commit 3410a97 into main Jul 13, 2023
4 checks passed
@shaydewael shaydewael deleted the onboarding/update branch July 13, 2023 17:46
Nihlus added a commit to Remora/Remora.Discord that referenced this pull request Jul 14, 2023
lukellmann added a commit to kordlib/kord that referenced this pull request Sep 17, 2023
The DSL looks like this:
val onboarding = guild.editOnboarding {
    enabled = true
    mode = OnboardingMode.Advanced
    defaultChannelId(channelId1)
    defaultChannelId(channelId2)
    defaultChannelId(channelId3)
    defaultChannelId(channelId4)
    defaultChannelId(channelId5)
    defaultChannelId(channelId6)
    defaultChannelId(channelId7)
    prompt(
        OnboardingPromptType.MultipleChoice,
        title = "prompt title",
        singleSelect = false,
        required = false,
        inOnboarding = true,
    ) {
        option(title = "option 1 title") {
            channelIds += someChannelId
            description = "option 1 description"
        }
        option(title = "option 2 title") {
            roleIds += someRoleId
        }
    }
}
println(onboarding)

See discord/discord-api-docs#6101
lukellmann added a commit to kordlib/kord that referenced this pull request Sep 17, 2023
The DSL looks like this:
val onboarding = guild.editOnboarding {
    enabled = true
    mode = OnboardingMode.Advanced
    defaultChannelId(channelId1)
    defaultChannelId(channelId2)
    defaultChannelId(channelId3)
    defaultChannelId(channelId4)
    defaultChannelId(channelId5)
    defaultChannelId(channelId6)
    defaultChannelId(channelId7)
    prompt(
        OnboardingPromptType.MultipleChoice,
        title = "prompt title",
        singleSelect = false,
        required = false,
        inOnboarding = true,
    ) {
        option(title = "option 1 title") {
            channelIds += someChannelId
            description = "option 1 description"
        }
        option(title = "option 2 title") {
            roleIds += someRoleId
        }
    }
}
println(onboarding)

See discord/discord-api-docs#6101
lukellmann added a commit to kordlib/kord that referenced this pull request Sep 17, 2023
The DSL looks like this:
val onboarding = guild.editOnboarding {
    enabled = true
    mode = OnboardingMode.Advanced
    defaultChannelId(channelId1)
    defaultChannelId(channelId2)
    defaultChannelId(channelId3)
    defaultChannelId(channelId4)
    defaultChannelId(channelId5)
    defaultChannelId(channelId6)
    defaultChannelId(channelId7)
    prompt(
        OnboardingPromptType.MultipleChoice,
        title = "prompt title",
        singleSelect = false,
        required = false,
        inOnboarding = true,
    ) {
        option(title = "option 1 title") {
            channelIds += someChannelId
            description = "option 1 description"
        }
        option(title = "option 2 title") {
            roleIds += someRoleId
        }
    }
}
println(onboarding)

See discord/discord-api-docs#6101
shaydewael added a commit to Jupith/discord-api-docs that referenced this pull request May 14, 2024
* Adds docs for Onboarding updates and new mode field

* Add constraints and info

* Update docs/resources/Guild.md

Co-authored-by: shay <swdewael@gmail.com>

* add error codes for onboarding

---------

Co-authored-by: shay <swdewael@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants