#discord-bots
1 messages Β· Page 455 of 1
@bot.group(invoke_without_command=True)
async def help(ctx):
#stuffs```
and then i have some commands like:
@help.command()
async def emoji(ctx):
#cmd des.
now can i use an error handler for all commands under that group?
I used @help.error
but it works only when the main help cmd raises exception
what is the error
you need the pynacl library
pip install pynacl
ok
no
Whats nextcord?
pip install discord.py[voice]
^ anyone ?
discord.py v2.0 fork
this```py
activity=discord.CustomActivity(
name="Listening to .help (msg me for modmail)",
emoji=None),
u wanna add en emoki to the status? @wooden garnet
okay wait
i just realized something
do you have intents enabled??
more specifically the presence intents
intents?
Yep yep
!intents
Using intents in discord.py
Intents are a feature of Discord that tells the gateway exactly which events to send your bot. By default, discord.py has all intents enabled, except for the Members and Presences intents, which are needed for events such as on_member and to get members' statuses.
To enable one of these intents, you need to first go to the Discord developer portal, then to the bot page of your bot's application. Scroll down to the Privileged Gateway Intents section, then enable the intents that you need.
Next, in your bot you need to set the intents you want to connect with in the bot's constructor using the intents keyword argument, like this:
from discord import Intents
from discord.ext import commands
intents = Intents.default()
intents.members = True
bot = commands.Bot(command_prefix="!", intents=intents)
For more info about using intents, see the discord.py docs on intents, and for general information about them, see the Discord developer documentation on intents.
You'll have to enable them both in your code, and developer portal. Let me know if it works!
You need to enable them and set them to True to make events and other such things work properly.
I'm not sure how to fully explain it, but it's most likely what's causing your issue
Some one help me here pls
I cant enable it
the switch is disabled
You have to be able to
What!??
i did not get it still i studied the whole document
commands.Bot has a activity kwarg
My bot is only in one server tho
You can still enable them
and they're talking ab verification but I can't verify if my bot is in one server
I'm not really getting anything from it, I'm sorry, I need the error
You don't need verification..
@slate swan
;-; I just ss the whole error part
@slate swan this is what happens when I try to verify
Okay, in the first screenshot you sent, the very bottom is an attribute error
ik but wht abt its status as idle

Can you say that the attribute error is?
No
i need to change status of discord bot to idle
I am just started so I understand very little
Okay? So do it
guys does anyone know what I should do?
bot = commands.Bot(**kwargs, status=discord.Status.idle)
@slate swan
I'm stuck at the part where you can change the status to a custom status
theres a like street sign thing
its disabled lol
lol I went in to inspect element and enabled it and now I saved the changes but I doubt it'll work
yea it doesn't stay
Why every time I execute the "serverinfo" command, I get "Owner: None" ?, I am occupying: {ctx.guild.owner}.
intents?
what is that? 
see what
1 sec
You probably don't have the members intent turned on.
not working
show me your intents.
but how do i activate it?
!intents
Using intents in discord.py
Intents are a feature of Discord that tells the gateway exactly which events to send your bot. By default, discord.py has all intents enabled, except for the Members and Presences intents, which are needed for events such as on_member and to get members' statuses.
To enable one of these intents, you need to first go to the Discord developer portal, then to the bot page of your bot's application. Scroll down to the Privileged Gateway Intents section, then enable the intents that you need.
Next, in your bot you need to set the intents you want to connect with in the bot's constructor using the intents keyword argument, like this:
from discord import Intents
from discord.ext import commands
intents = Intents.default()
intents.members = True
bot = commands.Bot(command_prefix="!", intents=intents)
For more info about using intents, see the discord.py docs on intents, and for general information about them, see the Discord developer documentation on intents.
knew it lol
lol
copy paste where
what
oh
just above/below intents.members = True
If your bot is unverified and is in 75+ servers then it's not going to be given privileged intents.
got it

not working
oh bruh
well
@slate swan go to your developer portal
and make sure it's on as well
ohk
thanks
oh bruh really?
Show how you defined intents
now i re oved it all
He did it all right
Ok
Can you for the last time send your bot constructor
I'm sorry either i'm missing something or i don't really know why it's happening
seems like nobody's gonna help me π
bro can u tell me some good memes api i dont want to use reddit.memes.hot.json one
um i am not sure just try searching some up maybe
Oh I did see your question but I am not sure
Sorry
π
"How to make a error handler for all commands in a command group" right?
yea yea
well it will take a long time for each command
can u suggest some
that's why i'm asking for a efficient way
see i use this
that's just a command handler
he wants a command handler for a group
that's not related to group commands

ohk
Haven't you considered just trying on_command _error event
So it's global
Makes it a lot easier tbh
mhm gotta try
It's fine man
how do i sent the error message like this if someone deletes the message which was being edited??
https://media.discordapp.net/attachments/381965515721146390/884838723676692632/unknown.png
thnx but now i can help some people to cause of u guys
!d discord.ext.commands.Context.message
The message that triggered the command being executed.
should be this
how?
sent the error message like this if someone deletes the message which was being edited
okay well, they probably just store the msg in a variable and continously edit it
so well, if there's an error in doing that, it should be because it got deleted maybe?
so try making an error handler
nice nice
u stalkings me??
no tf?
lol
wtf
then from no where u come and ping me
he no stock
check and see.
yooo i got a question
https://discordpy.readthedocs.io/en/latest/ext/commands/commands.html#error-handling
https://gist.github.com/EvieePy/7822af90858ef65012ea500bcecf1612
Simple Error Handling for ext.commands - discord.py - error_handler.py
whats the line used to detect a member joining the server
i mean which error does it come from
@lunar grove on_member_join
also guys chill with the pings
thx
!d discord.on_member_join
discord.on_member_join(member)``````py
discord.on_member_remove(member)```
Called when a [`Member`](https://discordpy.readthedocs.io/en/stable/api.html#discord.Member "discord.Member") leaves or joins a [`Guild`](https://discordpy.readthedocs.io/en/stable/api.html#discord.Guild "discord.Guild").
This requires [`Intents.members`](https://discordpy.readthedocs.io/en/stable/api.html#discord.Intents.members "discord.Intents.members") to be enabled.
i am still here
enable intents.
async def on_member_join @lunar grove
ik this bruh
@stiff nexus then?
i am not 100 sure, so try it and see.
ok
e nvm
Make it edit a message, and delete it, and see what error it raises
It's probably gonna be msg not found idk
then why u came in middle only to help me lol
help me how to find bot members in discord meaning bot accounts or bot added separate from members
number of bots in a guild?
bot_list = len(u for u in ctx.guild.members if u != bot.user)
I just noticed some ghostly behavior of my bot
It sends an error message out of nowhere
and the error message is of help command group
@help.error
async def help_error(ctx, error):
if isinstance(error, discord.ext.commands.errors.CommandError):
#the error msg
await ctx.send("pls use help command)
@slate swan wut
wat
u good
wdym
ok.
last line
uh
bro i just commented that out
lol
send error ss screen shot
Yeh already did and all but still
duhhhhhhh
No error comming bot is running and the Link isn't making
send screen shot of code lol
Ohh wait 
i have whole code u need
music bot??
It's not and bot it's an hosting tool 
But still in others language it's COMMING
wtf are u making send me server link in dm i will test and help u out
yes
can i make a global handler for this?
https://media.discordapp.net/attachments/381965515721146390/884838723676692632/unknown.png
Trying to edit a message which doesn't exist will raise discord.NotFound iirc
discord.NotFound can be raised for multiple reasons
MessageNotFound?
exception discord.NotFound(response, message)```
Exception thatβs thrown for when status code 404 occurs.
Subclass of [`HTTPException`](https://discordpy.readthedocs.io/en/stable/api.html#discord.HTTPException "discord.HTTPException")
f"{str(len(client.guilds))}"
not working
its not sending the defalt error
just do {len(client.guilds)}
Sorry, what do you mean?
ohk
@commands.Cog.listener()
async def on_command_error(self,ctx, error):
if isinstance(error, commands.CommandNotFound):
return
if isinstance(error,discord.NotFound):
message = f":not: The hack ended because someone deleted the message I was going to edit"
else:
message = f":not: {error}"
await ctx.reply(message)
error it gave is py Command raised an exception: NotFound: 404 Not Found (error code: 10008): Unknown Message
π
yeah, not found is raised
but its not sending my error message
Try adding error = getattr(error, "original", error) at the start of the function 
u restarted?
yes
u got ( before len
ohk
just {len(client.guilds)}
ohk
worked but what does this do?
still why not working
!d getattr 
getattr(object, name[, default])```
Return the value of the named attribute of *object*. *name* must be a string. If the string is the name of one of the objectβs attributes, the result is the value of that attribute. For example, `getattr(x, 'foobar')` is equivalent to `x.foobar`. If the named attribute does not exist, *default* is returned if provided, otherwise [`AttributeError`](https://docs.python.org/3.10/library/exceptions.html#AttributeError "AttributeError") is raised.
Note
Since [private name mangling](https://docs.python.org/3.10/reference/expressions.html#private-name-mangling) happens at compilation time, one must manually mangle a private attributeβs (attributes with two leading underscores) name in order to retrieve it with [`getattr()`](https://docs.python.org/3.10/library/functions.html#getattr "getattr").
send raw code
status = [f" {len(client.guilds)} servers!! \n Use $help for Command List",f"{len(client.guilds)} servers!! \n Use $invite for inviting me",f" {len(client.guilds)} servers!! \n Use $vote for voting me"]
Hey @cinder horizon!
It looks like you tried to attach a Python file - please use a code-pasting service such as https://paste.pythondiscord.com
!e status = [f" {len(client.guilds)} servers!! \n Use $help for Command List",f"{len(client.guilds)} servers!! \n Use $invite for inviting me",f" {len(client.guilds)} servers!! \n Use $vote for voting me"]
@slate swan :x: Your eval job has completed with return code 1.
001 | Traceback (most recent call last):
002 | File "<string>", line 1, in <module>
003 | NameError: name 'client' is not defined
reeeeeeeeeeeeeeeeeeeeeeeeee.......aight
These libs don't work in snekbox
hey so im coding a bot for my friends server, and ofc i need to give the bot admin perms but i cant grant them, is there any way he can grant them from his account to my bot?
or does giving the bot admin role in the server just work?
how do i embed a dictionary item?....like lez say m getting osu! scores n multiples embeds r to be sent....how do i do tht?
https://paste.pythondiscord.com/avozoquyin.py
well it work if i remove the client.guilds
u can always make permission calculator

You havent defined it
A small calculator that generates Discord OAuth invite links
if i inv the bot to the server, can my friend give the bot the "admin" role?
yes but
- You don't need admin for any bot. That depends on what the bot does and any bot can work without admin.
- Still if you want to, you can create an invite link with admin perms (permission integer = 8)
- Just giving Admin role also works fine
ight ty
wuts this?
I need help pls
running the command to import discord bot, (covering the token) and it opens a file instead of running, where should i save this file?
async is a reserved keyword in python
What dpy version are you using?
3.7.9
not python version, send the discord.py version
Did you install discord instead of discord.py?
I remember someone told me mirror package has this issue
π ..
shit

a text channel
yes
0.16.12
wtf
ok
how do you have 0.16
lol
He did pip install discord.py==0.16
Or you can downgrade your python version
Imagine asking for help with pass_context
how can i disable a button once its been clicked in dpy 2.0
Set the <button>.disabled = True and edit the whole message with the new view
hey so trying to just make the bot react to join and leave through the cmd but its not working like the tutorial video on yt
Is there like a way to inplement a status like uptimerobot or npm2 to ur discord bot, itβs hosted on windows vps tag if u have an answer or dm me
<View>.children returns the list of components in view, find the button by comparing the value/name/something else, and set it's disabled attr = False and edit the whole message @velvet crest
!e print('hi')
@slate swan :white_check_mark: Your eval job has completed with return code 0.
hi
#bot-commands @slate swan
alright thanks, also how do i provide a timeout parametr ?
While initialising view, pass it in super().__init__(timeout=...)
hey so trying to just make the bot react to join and leave through the cmd but its not working like the tutorial video on yt
Because that tutorial is probably outdated and you need member intents now for this
ah okay, should i stop following the tutorial? i mean it worked with getting the bot online
from mid 2019
yes xD
Instead of the tutorial, follow this https://vcokltfre.dev/
ahhh alot of text, scary
okie :p im tryna make it like a ping pong bot, where if someone says something it says something back
Nah that's a lot better than the current tutorial you're watching. 
what do i do with all this?
It's fine, just a bit poor way of doing. Read that guide
so i delete it all?
You can if you like
This is just a poor way of doing, and many people don't like this
Using intents in discord.py
Intents are a feature of Discord that tells the gateway exactly which events to send your bot. By default, discord.py has all intents enabled, except for the Members and Presences intents, which are needed for events such as on_member and to get members' statuses.
To enable one of these intents, you need to first go to the Discord developer portal, then to the bot page of your bot's application. Scroll down to the Privileged Gateway Intents section, then enable the intents that you need.
Next, in your bot you need to set the intents you want to connect with in the bot's constructor using the intents keyword argument, like this:
from discord import Intents
from discord.ext import commands
intents = Intents.default()
intents.members = True
bot = commands.Bot(command_prefix="!", intents=intents)
For more info about using intents, see the discord.py docs on intents, and for general information about them, see the Discord developer documentation on intents.
idk what any of that means
^ @distant oasis
ill stick to tutorial like akshu said
i need
help
pls
@client.command()
async def farm(ctx):
await open_account(ctx.author)
user = ctx.author
fruits = ["apples", "bananas", "oranges"]
totalmax = random.randrange(30)
workout = (totalmax*2.50)
await ctx.send(f"You got {totalmax}{fruits.choice} , therefore you earned Β£{workout}")
users = await get_bank_data()
users[str(ctx.author.id)]["wallet"] += workout
print(users)
with open ("Users.json", "w") as f:
json.dump(users,f)
@slate swan the guide doesnt rly asy how to start the bot like the other one, sorry if im not supposed to ping u
it just goes from creating teh bot on the website to "hello world"
The "hello world" has everything related to starting and all.

so i just put the first 2 lines of code in and my bot should just boot up?
ik it says below to input token
Continue reading, it's explained in steps
hello. where do i ask my doubts?
alsop why did u keep putting blobpain when u said lucas's name?
For #discord-bots , for #python-discussion
thanks
He's a legend in bot dev community. If you continue followed him, you probably get a lot of errors because you followed wrong (or outdated) tutorial. And any helpers will just get irritate and won't answer you 
Don't watch yt tutorials for discord bot, most of them are not very nice.

?
async def result(ctx, result):
result = str(result)
Team_A_channel = client.get_channel(870969338901954606)
Team_B_channel = client.get_channel(870969338901954607)
Team_A_members = Team_A_channel.members
Team_B_members = Team_B_channel.members
Team_A_members_id = []
for member in Team_A_members:
Team_A_members_id.append(member.id)
Team_B_members_id = []
for member in Team_B_members:
Team_B_members_id.append(member.id)
Team_A_members_mention = []
for member in Team_A_members:
Team_A_members_mention.append(member.mention)
Team_B_members_mention = []
for member in Team_B_members:
Team_B_members_mention.append(member.mention)
winning_team_lobby1 = ""
if result in ['Team A', 'team a', 'Team a', 'team A']:
winning_team_lobby1 = "Team A"
cursor.execute("UPDATE main SET Price = user_elo + (?) WHERE user_id IN [?]", (elo_win, Team_A_members_id))
db.commit()
user_elo doesn't change even after i use the cmd. no errors as well. what wrong? ping on reply
why is it an async function
it says at this point it should be working
@slate swan nothing
i ran it, the terminal is also blank if that means anything
Bot is running, you're just missing on_ready event.
did i miss it on the hello world page?
okay
its a cmd
but when i type "hello" in the disc server with the bot nothing happens
The built-in sqlite3 lib is blocking
hello or !hello?
im stupid.... xD
is there a way to make it withouth the !?
like i wanna make the bot reply to certain things, like if my friend says something itll reply back with some dumb inside joke we have
I think, just set it to "", but it'll listen to every message then and spam your console probably
Use on_message event
^
is there a part in the tutorial u sent me, cause idk how to do that
There's a guide about listeners, read that and you'll get how to use them
k
dont take the reply seriousily, inside joke iwth my friends :p
i got that bit of code from stack overflow, but idk half the words they use lol
That's not how you use listeners 
Just please continue reading it, once you finish it, your most of the doubts will be cleared
so i tried reading about listeners in python, but it was just confusing, but i found a different bit of code and now it works π
Listeners are not a part of python. If you don't know basics and a bit of oop, please stop dpy and bots and instead learn python first
meh its fine i got the bot working :p, learning python fully isnt rly a goal of mine, ill be doing bits of it in college this year, i dont rly learn from reading, i learn from watching ppl
so when u sent me like that page with a chunk of text, i kinda just copy pasted the highlighted parts cause reading all that was just not in my attention span
I want a help of embeds..... Just I want a command like !embed <colour in hex code> <description>, I know how to get description but I want colours in hex code like (.embed #fff00 this is an embed)
!d discord.Member.joined_at
A datetime object that specifies the date and time in UTC that the member joined the guild. If the member left and rejoined the guild, this will be the latest date. In certain cases, this can be None.
thx 
i am trying to get all members with a certain permission in the guild, how can i do it?
use int() and make use of the base arg, set that to 16
do note that the # cant be in the string you're passing
get_all_members_permissions
you mean the amount of users in a guild?
or the ids of the users
bro the users whu used the bot or interacted with it
its not even a thing just joking
I am not understanding please give me the code I will understand and just explain me in short what is base arg
async def result(ctx, result):
result = str(result)
Team_A_channel = client.get_channel(870969338901954606)
Team_B_channel = client.get_channel(870969338901954607)
Team_A_members = Team_A_channel.members
Team_B_members = Team_B_channel.members
Team_A_members_id = []
for member in Team_A_members:
Team_A_members_id.append(member.id)
Team_B_members_id = []
for member in Team_B_members:
Team_B_members_id.append(member.id)
Team_A_members_mention = []
for member in Team_A_members:
Team_A_members_mention.append(member.mention)
Team_B_members_mention = []
for member in Team_B_members:
Team_B_members_mention.append(member.mention)
winning_team_lobby1 = ""
if result in ['Team A', 'team a', 'Team a', 'team A']:
winning_team_lobby1 = "Team A"
cursor.execute("UPDATE main SET Price = user_elo + (?) WHERE user_id IN [?]", (elo_win, Team_A_members_id))
db.commit()β
user_elo doesn't change even after i use the cmd. no errors as well. what wrong? ping on reply
how does that relate to the code you sent
!code
Here's how to format Python code on Discord:
```py
print('Hello world!')
```
These are backticks, not quotes. Check this out if you can't find the backtick key.
Hey, so i have 3 sets of "on_message" commands, but only the last one makes the bot reply, i tried swapping the words and its only the last in the string, can anyone help
1 sec
use the integer method int(), pass the string and set the base argument to 16. Make sure to remove the # in the string
see @agile goblet
users
just get the length of bot.guilds and bot.users
only the bottom one works, any reason y? do i need to seperate em somehow
convert them to @bot.listen() or just put them all in one on_message
especially if its just 2 lines per event
{len(bot.users)}
bro only u need to use 1 event and put them all in one event
Are you telling like this ?
@bot.command()
async def embed(ctx, *, description, colour : int())
em = discord.Embed(
description = description,
colour=colour
)
await ctx.send(embed=em)
thnx
wdym? like if i say "hello" i want to it to reply with "hello"
i dont want it to also reply with "bye" etc
use elif lmao
me?
no that is absolutely not how methods work
bro just remove all other events wit hon_message
and then just leave it right there
Please can you give me the code i am very confused
Instead learn python basics before dpy
and please, go over the basics of python again
if you dont know how to use methods then dpy is only gonna confuse you more

good for me that I ain't in their place now. I also started with dpy without even knowing how to call a function
i only learned variables yesterday xd
also youre directly comparing the content of the message, in no universe can both statements be triggered
Bad
We don't give you the code, this is a help channel. You can ask for help but please learn python first 
Oh 12:00
?
Learn more Python. My path was a difficult one, and I don't recommend anyone going on it
I sent the code bruh π
im only here to code this one bot, im not interested in full on learning python
Where ?
not particually something i enjoy 
anybody still know the pokΓ©cord bot? well it got that feature that a pokΓ©mon disappears after some time. how do i implement this?
No please
what have i stumbled into
π
how do i get the nitro status of a member?.
I am already tired of @visual island doing that to seem innocent asf even when he is one of the naughtiest guy I ever met
It's like you need to fly a plane without knowing what is a plane. What do you expect then?
The message deletes or something?
to just watch random yt guides till it works :p

Hi lol (you forgot some h- BTW)
akshu did too!!
Is he he or she
I get different responses everyday
no, the thing just ends after a few minutes, the message deleting part is easy, i mean the part where it denies any new guesses after a specific amount of time
Who said kylee is a she?
Check
okay
I don't remember, but in this help channel 
how?
!d discord.ext.commands.Bot.wait_for @noble helm
wait_for(event, *, check=None, timeout=None)```
This function is a [*coroutine*](https://docs.python.org/3/library/asyncio-task.html#coroutine).
Waits for a WebSocket event to be dispatched.
This could be used to wait for a user to reply to a message, or to react to a message, or to edit a message in a self-contained way.
The `timeout` parameter is passed onto [`asyncio.wait_for()`](https://docs.python.org/3/library/asyncio-task.html#asyncio.wait_for "(in Python v3.9)"). By default, it does not timeout. Note that this does propagate the [`asyncio.TimeoutError`](https://docs.python.org/3/library/asyncio-exceptions.html#asyncio.TimeoutError "(in Python v3.9)") for you in case of timeout and is provided for ease of use.
In case the event returns multiple arguments, a [`tuple`](https://docs.python.org/3/library/stdtypes.html#tuple "(in Python v3.9)") containing those arguments is returned instead. Please check the [documentation](https://discordpy.readthedocs.io/en/stable/api.html#discord-api-events) for a list of events and their parameters.
This function returns the **first event that meets the requirements**...
So Kylee is now a girl. claps slowly sarcastically
I want to make a seperate files of command how do I make it.
!d discord.ext.commands.Cog
class discord.ext.commands.Cog```
The base class that all cogs must inherit from.
A cog is a collection of commands, listeners, and optional state to help group commands together. More information on them can be found on the [Cogs](https://discordpy.readthedocs.io/en/stable/ext/commands/cogs.html#ext-commands-cogs) page.
When inheriting from this class, the options shown in [`CogMeta`](https://discordpy.readthedocs.io/en/stable/ext/commands/api.html#discord.ext.commands.CogMeta "discord.ext.commands.CogMeta") are equally valid here.
ima check that out
damn my habits
Thank you very much
I'm already confused in typing a decorator since hours and now I'm gonna die 
always typing check with an a
π
Haha all cool
@visual island you gotta solve this mystery now 
I bet most of the people say him a she cz of his pfp
Maybe 
?
I can bet :D
Most of my code is just # type: ignore coz I can't figure out how do fix 
Ah mypy?
well i guess that command makes my bot main feature 5 times easier to program and makes half of my code on that worthless
welp, guess i have something to do
Pyright
Idk exactly what's mypy
Haha cool
Type checking
how to display member banner?
Available in 2.0
Not available in 1.7.3
member.banner
Also that only works with fetch
Hmm, idk about that. I never saw the docs for 2.0 lmao
even tho I am helping dev a dpy fork
No
Discord docs in any other website..?
I don't think something like that exists
Indeed
Though discord'd docs are pretty easy
discord.version
pip show discord.py
trolled
!d discord.version
discord.__version__```
A string representation of the version. e.g. `'1.0.0rc1'`. This is based off of [**PEP 440**](https://www.python.org/dev/peps/pep-0440).
Lol
Eh?
In cmd
Breh, I use Python in cmd
@commands.command()
@commands.cooldown(rate=1, per=10, type=commands.BucketType.user)
@commands.guild_only()
@commands.check(permissions.is_owner)
async def hoist(self, ctx: commands.Context):
"""Changes users names that are hoisting themselves (Ignores Bots)"""
chars = ['!', '.', '-', '_', '*', '(', ')', '=', '+', '^', '&', '~', '#', '$', ':', ';', '?', '<', '>', '{', '}', '[', ']', '|', '\\', '"', "'", '`']
temp = {}
failed = 0
initial = await ctx.send("Kk, changing peoples names. This'll take some time so please be patient!")
async with ctx.typing():
for member in ctx.guild.members:
if not member.bot:
for char in chars:
if member.display_name.startswith(char):
try:
await member.edit(nick=member.display_name.replace(char, ''))
except discord.HTTPException:
try:
await member.edit(nick="No Hoisting")
except discord.Forbidden:
failed += 1
except discord.Forbidden:
failed += 1
temp.update({char: temp.get(char, 0) + 1})
if member.display_name[0].isdigit():
try:
await member.edit(nick="No Hoisting")
temp.update({"numbers": temp.get("numbers", 0) + 1})
except:
failed += 1
stats = '\n'.join([f"`{char}` - `{amount}`" for char, amount in temp.items()])
await initial.edit(content=f"I have unhoisted `{sum(temp.values())}` nicks and failed to edit `{failed}` nicks.\nHere are some stats:\n\n{stats}")
``` whatcha think
Pasting large amounts of code
If your code is too long to fit in a codeblock in discord, you can paste your code here:
https://paste.pydis.com/
After pasting your code, save it by clicking the floppy disk icon in the top right, or by typing ctrl + S. After doing that, the URL should change. Copy the URL and post it here so others can see it.
Woah
Its fine
Pretty please π₯Ίπ
I code in IDLE. Take that
I can screenshot it for you
What's that btw, Looks like a massive loop command
Same
Anyways I'mma crash. Gn
h- hun- Goodnight blushes
no

Also I feel like ratelimits-
@slate swan I have asked you that how to set custom colour in embeds using hex code and also u answered it but please can you give me the code please I am very confused
K but tell me how to use it
bot owner
!d discord.ext.commands.is_owner
discord.ext.commands.is_owner()```
A [`check()`](https://discordpy.readthedocs.io/en/stable/ext/commands/api.html#discord.ext.commands.check "discord.ext.commands.check") that checks if the person invoking this command is the owner of the bot.
This is powered by [`Bot.is_owner()`](https://discordpy.readthedocs.io/en/stable/ext/commands/api.html#discord.ext.commands.Bot.is_owner "discord.ext.commands.Bot.is_owner").
This check raises a special exception, [`NotOwner`](https://discordpy.readthedocs.io/en/stable/ext/commands/api.html#discord.ext.commands.NotOwner "discord.ext.commands.NotOwner") that is derived from [`CheckFailure`](https://discordpy.readthedocs.io/en/stable/ext/commands/api.html#discord.ext.commands.CheckFailure "discord.ext.commands.CheckFailure").
so, only i and the people in my owner config can run it
Why not this then?
Oh okay
You can also customize owner_ids then in the bot constructor and will still work fine
Yeah then it's good (and only option) 
@clear comet have a command with description and color args and then initialise an embed and try setting description and color to what was provided in description and color command args, except it probably raised an error of something so just return and do something or use an error handler
Ok how do I use color command args ?
Use ctx, *, description, color
User passes in hex
Guys is there any tutorial that explains how to make a rest api with quart
Thank you veryuch you helped me alot
What
think about it
if it consumes rest
that will happen for the description
but what about color
Anyone?
Ok I understood but for color I need to just keep it blank right
Or put description in speech marks will it work blanket? It should right
like this !embed "description lol" color?
Yes
Yeah
Ok
hey so i got the bot working to an extent, it works with single words, but cant pick the word out of a sentence, can someone tell me how, or tell me what to search cause idk what to search on stack overflow either
@bot.command(aliases=['ΠΏΠ΅ΡΠ΅Π²ΠΎΠ΄','ΠΏΠ΅ΡΠ΅Π΄Π°ΡΡ'])
async def pay(ctx,member:discord.Member,arg:int):
await ctx.channel.purge(limit = 1)
with open('economy.json','r') as f:
money = json.load(f)
if money[str(ctx.author.id)]['Money'] >= arg:
msg1 = await ctx.send(
embed = discord.Embed(title = 'ΠΠ΅ΡΠ΅Π²ΠΎΠ΄ Π΄Π΅Π½Π΅Π³', timestamp = ctx.message.created_at, description=f'{ctx.author.mention}, Π²Ρ ΡΠ²Π΅ΡΠ΅Π½Ρ ΡΡΠΎ Ρ
ΠΎΡΠΈΡΠ΅ **ΠΏΠ΅ΡΠ΅Π΄Π°ΡΡ {arg}** ΠΌΠΎΠ½Π΅Ρ {member.mention}?'),
components = [
Button(style = ButtonStyle.green, label = 'ΠΠ°', emoji = ':heavy_check_mark:'),
Button(style = ButtonStyle.red, label = 'ΠΠ΅Ρ', emoji = ':x:')
])
responce = await bot.wait_for('button_click', check = lambda message: message.author == ctx.author)
if responce.component.label == 'ΠΠ°':
#await responce.respond(content = 'ΠΠ΅Π½ΡΠ³ΠΈ ΡΡΠΏΠ΅ΡΠ½ΠΎ ΠΏΠ΅ΡΠ΅Π²Π΅Π΄Π΅Π½Ρ!')
msg2 = await msg1.edit(
emb = discord.Embed(title='ΠΠ΅ΡΠ΅Π΄Π°ΡΠ° ΠΠ΅Π½Π΅Π³', color=0xB700FF, description=f'{ctx.author.mention} **ΠΏΠ΅ΡΠ΅Π΄Π°Π»** {member.mention} **{arg}** ΠΌΠΎΠ½Π΅Ρ!', timestamp = ctx.message.created_at),
# #emb.set_thumbnail(url=ctx.author.avatar_url)
βemb.set_footer(text='ΠΠΎΠΌΠΈΡΡΠΈΠΈ ΠΏΡΠΈ ΠΏΠ΅ΡΠ΅Π²ΠΎΠ΄Π΅ ΡΠΎΡΡΠ°Π²ΠΈΠ»Π° 5%'),
components = [
Button(style = ButtonStyle.green, label = 'ΠΠ°', emoji = ':heavy_check_mark:'),
]
)
money[str(ctx.author.id)]['Money'] -= arg
money[str(member.id)]['Money'] += arg - (arg / 100 *5)
channel = bot.get_channel(876731607837458432)
emb = discord.Embed(title='ΠΠ΅ΡΠ΅Π²ΠΎΠ΄', color=0x0011FF)
emb.add_field(name='> \*\*ΠΠ΅ΡΠ΅Π²ΡΠ»:\*\*',value=f'\`\`\`{ctx.author}\`\`\`')
emb.add_field(name='> \*\*ΠΠΎΠΌΡ:\*\*',value=f'`\`\`{member}`\`\`')
emb.add_field(name='> \*\*Π‘ΡΠΌΠΌΠ°:\*\*',value=f'\`\`\`{arg} ΠΌΠΎΠ½Π΅Ρ`\`\`')
emb.set_thumbnail(url=ctx.author.avatar_url)
emb.set_footer(text=f'ΠΠ²ΡΠΎ-ΠΠΎΠ³ΠΈΡΠΎΠ²Π°Π½ΠΈΠ΅ ΠΠ΅ΡΠ΅Π²ΠΎΠ΄ΠΎΠ²')
await channel.send(embed = emb)
else:
#await responce.respond(content = 'ΠΡ ΠΎΡΠΌΠ΅Π½ΠΈΠ»ΠΈ ΠΏΠ΅ΡΠ΅Π²ΠΎΠ΄.')
emb = discord.Embed(title='ΠΡΠΌΠ΅Π½Π° ΠΠ΅ΡΠ΅Π²ΠΎΠ΄Π°',timestamp = ctx.message.created_at, description=f'{ctx.author.mention},Π²Ρ **ΠΎΡΠΌΠ΅Π½ΠΈΠ»ΠΈ** ΠΏΠ΅ΡΠ΅Π²ΠΎΠ΄ **{arg}** ΠΌΠΎΠ½Π΅Ρ ΠΏΠΎΠ»ΡΠ·ΠΎΠ²Π°ΡΠ΅Π»Ρ {member.mention}')
emb.set_thumbnail(url=ctx.author.avatar_url)
await msg1.edit(embed=emb)
else:
emb = discord.Embed(title = 'ΠΡΠΈΠ±ΠΊΠ° ΡΡΠ°Π½Π·Π°ΠΊΡΠΈΠΈ', color = 780000, description=f'{ctx.author.mention}, Ρ Π²Π°Ρ **Π½Π΅** Π΄ΠΎΡΡΠ°ΡΠΎΡΠ½ΠΎ ΡΡΠ΅Π΄ΡΡΠ² Π΄Π»Ρ ΠΏΠ΅ΡΠ΅Π΄Π°ΡΠΈ **{arg}** ΠΌΠΎΠ΅Π½Ρ ΠΏΠΎΠ»ΡΠ·ΠΎΠ²Π°ΡΠ΅Π»Ρ {member.mention}')
emb.set_thumbnail(url=ctx.author.avatar_url)
emb.set_footer(text='ΠΠΎΠΏΡΠΎΠ±ΡΠΉΡΠ΅ ΠΏΠΎΠ²ΡΠΎΡΠΈΡΡ ΡΡΠ°Π½Π·Π°ΠΊΡΠΈΡ ΠΏΠΎΠΉΠΆΠ΅.')
await ctx.send(embed = emb)
with open('economy.json','w') as f:
json.dump(money,f)
plz help
!code
Here's how to format Python code on Discord:
```py
print('Hello world!')
```
These are backticks, not quotes. Check this out if you can't find the backtick key.
and what is the error
i have a blacklist word system. Its deleting the word that is only in the string which it means if i type Word
with upper case it doesnt deleting
That sucks
?
show the code
Just see: if word.lower() in message.content.lower() ig
No need for an unneeded call
You can just do if "lowercased word" in message.content.lower()
For discord.py I have all my code on repl.it now how do I host it 24/7
What's the difference?
is there a way to send a message to a channel with id id without a command, whenever an if statement is confirmed?
if true:
channel.send("true")```something like this ^
yeah but when do you want that executed
throw it into a function
and call the function whenever you wanna check
or you could set up a task if you'd like
await def now():
channel = bot.get_channel(12345)
await channel.send('test')
if True:
now()```?
!e ```py
import timeit
a = timeit.timeit("'Hello World'.lower() in 'Hi Hello World Something'.lower()", number=1000)
b = timeit.timeit("'hello world' in 'Hi Hello World Something'.lower()", number=1000)
print(a)
print(b)
@pale turtle Minor differences but yes
well yeah but this would constantly send messages. Where is your condition?
For discord.py I have all my code on repl.it now how do I host it 24/7
even if its not in a while loop?
heroku might help
!e ```py
import timeit
a = timeit.timeit("'Hello World'.lower() in 'Hi Hello World Something'.lower()", number=100000)
b = timeit.timeit("'hello world' in 'Hi Hello World Something'.lower()", number=100000)
print(a)
print(b)
@slate swan :white_check_mark: Your eval job has completed with return code 0.
001 | 0.03317045792937279
002 | 0.019162433221936226
Oh I thought they hve the word from some db to check
Almost double
But I need it to be in an ide for heroku
Ah yea if they have db, then it's required
Replit is not a hosting service
look into aws they might have a free tier available
its returning RuntimeWarning: Enable tracemalloc to get the object allocation traceback
async def testing():
channel = bot.get_channel(12345)
await channel.send('test')
testing()```
async def testing():
channel = bot.get_channel(12345)
await channel.send('test')
await testing()
"await" allowed only within async function
error is clear
Is that from my code?
yh
no
oh
you are using await outside
the outer one
he did await testing() outside of an async function
Ik but I have the code in repl.it so how can I host it
I did that oops
you canβt
replit is not a hosting service
replit is not a hosting service = you cannot host on it
Ok
yup, is there an alternative ?
But what should I do then
buy a vps or self host
Get a cheap or free (trials or free tiers) vps
virtual private server
def testing():
channel = bot.get_channel(12345)
await channel.send('test')
testing()
Can u send me one?
huh is that gonna work?
Like a link
that wonβt work?
Or soemthing
thats what i sent before π
await is only allowed inside async functions
hehe usually i go from the errors
RuntimeWarning: Enable tracemalloc to get the object allocation traceback
but there you could use loop.run_until_complete but i donβt think it would work if the bot is running
This is vexing me a little to be honest. How are you supposed to await the function from the global scope then?
yup, already tried ^ @hasty iron
is the bot running?
yeah
do you want to run that function before starting the bot
gives this error though AttributeError: 'NoneType' object has no attribute 'send'
oh
But how can I use the code I have on repl.it
async def testing():
channel = bot.get_channel(12345)
channel.send('test')
bot.loop.create_task(testing())```
If I use a vps
wait are you calling that function, before or after starting the bot
no need for async def there
Just copy it over to the vps
Alr
no more errors after putting it after bot.run
but not sending anything either
bot.run blocks
Is spotify api so slow or am I doing something wrong? It's like taking 10-12 seconds for each call.. 
where should it be placed, I placed it right before bot.run and it gave that error again
At last of everything
sometimes it can return huge jsons but from what i know its not that slow
Yeah it's spamming my console, but same time is taken for auth (client credentials)
Okay my vscode broke
a lot of data
it seems fine from their side https://status.spotify.dev
Welcome to Spotify Web API's home for real-time and historical data on system performance.
It's just auth then taking time. I used search endpoint and vscode is not able to handle it
in a procfile when I have to files for my discord bot what would I do
do i write a comma in between them
or do I write another line of worker: python example.py
Is there anything special I have to do at slash commands? I have installed them and now no slash commands have been created
Like I also added this code;
@slash.slash(name="test")
async def test(ctx: SlashContext):
embed = Embed(title="Embed Test")
await ctx.send(embed=embed)
And I also defined slash and everything
Is there anyway I can get multiple workers on heroku
Is there anyway I can get multiple workers on heroku
I can't import the load_dotenv module from the dotenv for some reason, it always gives me this error:
ImportError: cannot import name 'load_dotnev' from 'dotenv'
load_dotnev
ooo
Global slash commands can take up to 1 hour to register
Ohhh
Thanks for that, wouldn't figure that out for a couple of hours
For testing, set some guild ids so that it'll appear instantly
wdym with "set some guild ids"?
Slash commands can also be created for just a guild
Oh and how?
Idk about the lib you're using, but it may have some guild_ids=[] in the slash deco
check the docs
discord_slash
Alright
Uhm didnt work, I still cant see them on my server
But yea Ill look at the doxs
hey, what would y'all recommend as a good discord.py fork with slash commands
I haven't taken a look at many, but the author of dislash.py has created a fork called disnake
https://github.com/EQUENOS/disnake
thanks I'll check it out
Code:
import os
import discord
from discord.ext import commands
from dotenv import load_dotenv
Error:
Traceback (most recent call last):
File "c:/Users/Maria Augusta/Desktop/Besteiras de Programador/VSCode/Python/Projetos/LasagnaBot/Main.py", line 6, in <module>
from dotenv import load_dotnev
ImportError: cannot import name 'load_dotnev' from 'dotenv' (C:\Users\Maria Augusta\AppData\Local\Programs\Python\Python38-32\lib\site-packages\dotenv\__init__.py)```
What's up with this?
OOOOH, I DIDN'T SAVE
Jesus, I'm slow today
yeah it was running code with a typo "load_dotnev"
Well could you suggest any thats actually good?
Suggest what? Slash commands wrapper?
I don't code bots, so no idea about any
Or make your own
How do I do something when a role is added to user (ping me)
Oh ok welp then
await interaction.channel.history(oldest_first=True, limit=1).flatten()``` Is my code currently, how can I get the mention out of that message and bring the mention to a user ID? I've been working on this for for quite some time and I really need guidance to finish this. Thank you!
!d discord.Message.mentions
A list of Member that were mentioned. If the message is in a private message then the list will be of User instead. For messages that are not of type MessageType.default, this array can be used to aid in system messages. For more information, see system_content.
Warning
The order of the mentions list is not in any particular order so you should not rely on it. This is a Discord limitation, not one with the library.
So
This asked me to build a bot that apparently locks the channel to a certain group of people for a certain period of time
Anyone willing to give me a push on how I should start building the timer?
how do i take input from a command
!command
test hi
dsklf
and get all the args including the new line
what should I swap to since discord.py is now deprecated
Disnake
ok
How I add more than 1 worker in heroku
How would i go about coding a login command? If i were to type {prefix} login i want it to say how to login and then i want it to login when i type {prefix}login <code>
catch the discord.MissingRequiredArgument exception
and send the message in an error handler
Easier would be make that argument optional and just check if it is None or not ```py
def foo(x: Optional[Whatever_typehint] = None):
if not x:
return send_login_help()
return login_user()
how can i make my commands work with partial names?
hey
anyone wanna help me make a bot
are help me learn to script a bot
cause i need help
?
this is off the top of my head but you could use difflib.get_close_matches
!d difflib.get_close_matches
difflib.get_close_matches(word, possibilities, n=3, cutoff=0.6)```
Return a list of the best βgood enoughβ matches. *word* is a sequence for which close matches are desired (typically a string), and *possibilities* is a list of sequences against which to match *word* (typically a list of strings).
Optional argument *n* (default `3`) is the maximum number of close matches to return; *n* must be greater than `0`.
Optional argument *cutoff* (default `0.6`) is a float in the range [0, 1]. Possibilities that donβt score at least that similar to *word* are ignored.
The best (no more than *n*) matches among the possibilities are returned in a list, sorted by similarity score, most similar first.
oh poggers
and what does that do?
how would i use this though? like would i have to make a class for it
it gets the closest matches for a word from a given list
it can be inaccurate though
Depending on the cutoff you can receive back multiple words, you will need to handle that
and youβll need a list of guild member names
what does the cutoff mean exactly
read
ah
Command raised an exception: AttributeError: 'str' object has no attribute 'send'
error
class Misc(commands.Cog):
def __init__(self, bot):
self.bot = bot
@commands.command(name="toggle", description="Enable or disable a command!")
@commands.is_owner()
async def toggle(self, ctx, *, command):
command = self.bot.get_command(command)
if command is None:
await ctx.send("I can't find a command with that name!")
elif ctx.command == command:
await ctx.send("You cannot disable this command.")
else:
command.enabled = not command.enabled
ternary = "enabled" if command.enabled else "disabled"
await ctx.send(f"I have {ternary} {command.qualified_name} for you!")
def setup(bot):
bot.add_cog(Misc(bot))```
code
but youβll have to also make a custom converter class to make use of it
Im not sure how to do any of that
I struggle with classes as it is
can someone tell me how to fix
Is there a way to see what position someone is in a server? i.e if they are the 50th member then it would say something like member: 50 or 50th member rather than just the full member count
how do i convert a number like this: 3298761 to this: 3,298,761 in my discord bot?
"{:,}".format(3298761)
unless you store the data bofore anyone else joines then no
hmm, wonder how carl bot does it then since that bot is written in d.py and has that functionality
Or using f-string f"{3298761:,}"
he probable stores the data before
U want it to be in the order they joined?
yeah, so would i need to add their join pos to my db when they join and then take that value for when they leave
You could sort it out
only thing that can help you is by learning basic python, i think you're not ready to make a discord bot yet.
the fact that you dont know what "str" is, says it all
and following menu docs is probably a bad idea if you dont know basic python
ik basic python...
if you do then you should know how to fix that by yourself
attribute errors are part of basic python
i cant see it
_data = {}
index = 0
for m in _guild.members:
_data[m.name] = m.joined_at
for i in sorted(_data.items(), key=lambda item: item[1]):
print(f"{index}. {i[0]}")
index += 1
if you know basic python you should be able to understand what the error means
That's how you can do it, no need to store
wait is it this
the error literally tells you where the error is
def __init__(self, bot):
self.bot = bot
@commands.command(name="toggle", description="Enable or disable a command!")
@commands.is_owner()
async def toggle(self, ctx, *, command):
command = self.bot.get_command(command)
if command is None:
await ctx.send("I can't find a command with that name!")
elif ctx.command == command:
await ctx.send(You cannot disable this command.)
else:
command.enabled = not command.enabled
ternary = "enabled" if command.enabled else "disabled"
await ctx.send(f"I have {ternary} {command.qualified_name} for you!")
def setup(bot):
bot.add_cog(Misc(bot))```
look at it closely and see what line it points to
is it that
idk is it?
can you send the full traceback
which line does the error point to?
Do you see anything wrong when u send the message after the line elif ctx.command == command π€¨
i didnt put quotations?
Yes
thanks for that, i appreciate you sharing it
Yw
wont just doing _data[m] = β¦ since two people can have the same name
but i dont see any error
He's looking for the index of it, if he stores the sorted data he could just do data[index]
Which will return a tuple with the first value being the member's name and the 2nd being their join date which is a datetime object
my point is if two people have the same name one will override the other
yeah so wont it better to store it as a mapping of Member and datetime obj
Ig
if you saw this before it was edited i just made a noob mistake, sorry.
what
I'm sleeping 
how can i get a user obj not in the current server, tried using discord.Object() but returned nonetype
best thing to do is say they
how do i convert a number like this: 3298761 to this: 3,298,761 in my discord bot?
use .format with {:,}
!e
print("{:,}".format(100000))
@kindred epoch :white_check_mark: Your eval job has completed with return code 0.
100,000
oh
You don't need .format
wow thx so much β€οΈ
hm
@bot.command()
@commands.has_permissions(manage_roles = True)
async def mute(ctx, user : discord.Member):
roleobject = discord.utils.get(ctx.message.guild.roles, id=869784877594206249)
await ctx.send(f":white_check_mark: {user} was mute")
script is not giving the user the muted role
is there any other way?
you are not giving the role
you have to actually add the role
await user.add_roles(roleobject)
and you could just do: ctx.guild.get_role(role id)
normal f string also works (format is oldish)
how tho
can you show an example
!e
print(f"{100000:,}")
@visual island :white_check_mark: Your eval job has completed with return code 0.
100,000
that
oh
f"{var name}"
ik how to use f strings
i just didnt know where to add the number
thats an f string example, they wanted to know how to format numbers correctly using an f string
ok
i get it now
Had to dip for a sec but yea that
how do i move a role with a bot?
I've tried discord.Client.move_role() but it throws an error
await edit(*, reason=None, **fields)```
This function is a [*coroutine*](https://docs.python.org/3/library/asyncio-task.html#coroutine).
Edits the role.
You must have the [`manage_roles`](https://discordpy.readthedocs.io/en/stable/api.html#discord.Permissions.manage_roles "discord.Permissions.manage_roles") permission to use this.
All fields are optional.
Changed in version 1.4: Can now pass `int` to `colour` keyword-only parameter.
ty
!e py print(f"{102938292938:,}")
@patent lark :white_check_mark: Your eval job has completed with return code 0.
102,938,292,938
!e
print(f"{1029382.92938:,}")
@visual island :white_check_mark: Your eval job has completed with return code 0.
1,029,382.92938
cool
oops
!e
print(f"{2663**2:,}")
@visual island :white_check_mark: Your eval job has completed with return code 0.
7,091,569
I don't think you should be spamming commands here Β―_(γ)_/Β―
s-s-sorry 
command line to set a bots about me?
none
wh-
you can only set it from developer portal
ohhhhhh
currently
You guys know how to get to a messages response to another message if it was tagged?
does interaction responses really doesn't have rate limit?
Does someone have a code a discord bot code coded with python that make the user choose and change the prefix with
a command like "+setprefix" i searched all the day but i didnt find my phone is going low in battery if someone got that pls send me the code i will be thankful
does someone know how to split embed messages if the fields are over 6000 letters?
summarise the length of all strings
yes all IDEs can work
even notepad, not that i would recommend it
thanks!
we do not spoonfeed
i have been learning alot of python cause of this server.
its names so they're specific, how do i summarise that?
wdym, every field has a string as the text argument. You can take the length of that and summarise all the integers
yes but isnt that cutting some names?
Do i need to hide my bots token if i use visual studio code?
what do you mean by that exactly?
no you dont, its saved locally so just dont share it
i need a way to send multiple embeds because the length of my embed exceeds the limit
can someone somehow find it.
vsc isnt online and everything you do on it is stored on your computer so unless you give someone your code then no one else should get your token
is it just one field? That would mske it easier
otherwise im gonna have to rethink my advice
it isnt but if you want i can make it one field
hello!
the leave command is acting as if it's part of the play command and saying theres an unexpected indent
ive indented it but then the ) is saying unindent does not match any level
This can only be done on the master branch of discord.py
The abc.Messageable.send method has an embeds kwarg which you pass as a list of embeds
i guess it would work either way. What you could do is find the maximum length, cut the string there, split it by spaces and then remove the last index of the list ( except if the last index in the cut string is a space ofcourse ) and then just join the list to get a string back
Otherwise I would suggest using a list paginator from discord.ext.menus
can still send 2 msges
Which uses reactions to change pages
I'd rather send one single message rather then take up 2 api calls
if it works it works
ill try this then if it dosent work ill just add it as pages, thanks you two c:
i tried to run my bot on visual studio code it said couldnt find discord.
so what do i do.
you need except/else/finally clause after try
pip install discord.py
^
not everything has to be optimal though does it
k.
if theres no better option
Ok, so If I have 50 embeds I have to send 50 messages?
thank u
Great solution lol
If you already installed dpy from the terminal then make sure your vsc is using the right python path
yeah but we're not talking about 50 embeds now
If you were using v2.0 (master) you can send 5 messages each with 10 embeds max
Thats very much better then sending 50 messages for a single embed in each one

never said it wasnt better though
I'm pretty sure interaction responses do have a ratelimit
but they aren't global rather only on that interaction
wdym
so if I edit the response 10 times it won't add the global rate limit by 10?
I'm not sure, best bet is to make a quick http request that does an interaction response and check the response headers
It should contain X-ratelimit-remaining irrc
And some other relevant data towards ratelimits
hmm
I see, I'll try it later
??????????
As name suggests I'd assume it would generate snippets for you to use
Of course snippets being snippets won't make the whole thing
You use vsc as an IDE where you write the code
I would suggest downloading the python extension for vsc
i cant find it?






