skip to Main Content

Reactjs – React Use state run twice

I'm trying to run my Setup function once when the Discord Activity loads (https://discord.com/developers/docs/activities/how-activities-work). My code somehow runs the function twice and creates an error. Here is the code I'm using: function App() { const [auth, setAuth] = useState<authType>(null); async…

VIEW QUESTION

Php – Discord api returns nothing

I try to use this api to get a list of all guilds a user is in, but when i print the response i just see a blank screen. <?php session_start(); $url = "https://discord.com/api/users/@me/guilds"; $data = array('Content-Type: application/x-www-form-urlencoded', 'Authorization: Bearer…

VIEW QUESTION

Javascript – Discord.js creating channel within category

const guild = interaction.guild; const user = interaction.user; const ticketChannelName = ticket-${user.username}` // create category if not exits const category = guild.channels.cache.find(c => c.name == 'TICKETS' && c.type == ChannelType.GuildCategory); console.log() if(!category) { await interaction.guild.channels.create({ name: 'TICKETS', // The name…

VIEW QUESTION

Firebase Discord OIDC (Open ID)

Been looking for a way to connect Discord Auth with Open ID I have done all the steps according to the Firebase Open ID documentated found: https://firebase.google.com/docs/auth/web/openid-connect?hl=en&authuser=0 I have found a similar Auth provider using OpenID to connect to Discord…

VIEW QUESTION

Javascript – How can I solve the error in my python code?

I'm making a Discord bot with Python, the code is the following: embed = discord.Embed(title=f'Topic: {tema.capitalize()}', description='The word has ' + str(len(secretWord)) + ' letters', color=discord.Color.yellow()) msg = await interaction.response.send_message(embed=embed) await msg.add_reaction('regional_indicator_1:') It gives me the following error that I…

VIEW QUESTION
Back To Top
Search