💡Getting Started
Here is a step-by-step guide on how to start using Discord.swift
Last updated
Here is a step-by-step guide on how to start using Discord.swift
Last updated
Create your application via the Discord developer portal. Click on New Application.
Click on your application and navigate to the URL generator. Select the scopes as shown below.
Scroll down and you'll see Bot Permissions. Select the permissions you'd like the bot to have. For a very basic bot, I'd recommend adding the following permissions.
Read Messages/View Channels
Send Messages
Send Messages in Threads
At the bottom of the page, you'll see the URL. Copy & paste that URL into your browser and you'll be able to select which server to add the bot.
To access the API, you'll need a bot token. Your token is essentially your API key that authorizes your bot to interact with Discord. You can access your token by navigating to Bot and clicking on Reset Token.
Important: Your token should be kept private at all times. If someone gains access to your token, they can control your bot! 😳 Do not share your token with anyone you wouldn't trust having 100% control over your bot.
Last step, intents. What are intents? Intents are what controls which events are dispatched from Discord to the bot. For example, if the message content intent is disabled, you won't be able to read messages. The following Privileged Intents should be enabled.