Closed SGA-A closed 9 months ago
We have decided this is no longer being implemented as it is redundant. In simple terms, we do not see a use for this feature at the moment. It is also a breach of privacy and Discord's Developer Policy does not approve of this.
Is your feature request related to a problem? Please describe. Sniping (aka logging) is a feature that not many bots have, but would be great to have. If someone wants to know what the contents of a message was after it was deleted, we would need to store it somewhere. This includes attachments that range from a voice message to a normal message with content in it.
Describe the solution you'd like
Do not: Snipe messages from bots Snipe messages from DMs.
Do: Enable the intents required for the
on_message_delete
event to be dispatched. Snipe messages from guilds.For images and videos/GIFs, I don't particularly like the thought of storing every single file locally so perhaps we could use an image hosting website, like Imgur. For voice messages, these will probably be downloaded. For normal messages with content, these will be stored within a new table within the db.
Describe alternatives you've considered Store every message as it is sent, then when it is deleted just fetch its ID. This is very space-consuming, but it may be necessary if at the time of the message deletion, the attachments within the content are no longer available (due to expiring cdn links) or the message is particularly old. This means storing the message ID as the row within a database, and the different types of content within their respective fields.
Additional context When you delete a message on Discord, the content of the message is removed from the chat for all participants. However, Discord retains logs of messages on its servers for a certain period of time, as part of their data storage. This is known as 'the retention period'. The deleted messages may still be accessible through Discord's internal logs during this retention period.
This means that for sniped messages of a user to be accessible within the long run, its associated data must be stored.