#Message ID

1 messages · Page 1 of 1 (latest)

lofty folio
#

How can you retrieve the message ID of either the last message a user sent or of a message that contains a specific string?

noble sequoia
#

Well Discord doesn't expose the search API to bots, so you'd have to either keep track manually, or fetch and filter

lofty folio
#

How do you fetch and filter?

noble sequoia
#

@deft bone GetMessagesAsync

deft boneBOT
noble sequoia
#

From there, you iterate the results and grab whatever message is relevant for you

lofty folio
#

I see I'll look into this thank you!

topaz wolf
#

Also, you can subscribe to the MessageCreated event and track the last message a user sent in real time

topaz wolf
#

They might not know what you meant by that

#

Smh my smh