1
votes

I'm creating a bot that monitors stuff online, and I have the code done and it runs in Terminal. I want to print my results within a channel in Discord using discord.py without having to require a command/input from a Discord user. I just want my program to send a message to my server in Discord when it picks up a product online. How can I do this?

1
Look into using webhooks. And the docs in case you're interested in incorporating it into a bot.Diggy.

1 Answers

0
votes

You have to get the channel from id then send it using send.

Code (assuming your client is client):

channel = client.get_channel(123456789) # get channel from id
await channel.send('message here') # send message