discord-downloader-go

A Discord bot program to download and otherwise handle files sent in Discord channels with extensive configuration. Can be used as a genuine Discord Bot or user account / self-bot

MIT License

Stars
275

Bot releases are hidden (Show)

discord-downloader-go - v1.6.1

Published by get-got about 3 years ago

  • Overhauled console logging/formatting
  • Added support for settings.jsonc configurations in place of settings.json, for JSON commenting
  • Added "blacklistChannels" (settings.servers[].blacklistChannels) to blacklist channels from server configs
  • Added "divideLogsByStatus" (settings.channels[].logLinks.divideLogsByStatus), only used if destinationIsFolder is true, separates log files by download status. Only applies to logLinks, not logMessages
  • Added "logDownloads" (settings.channels[].logLinks.logDownloads), only applies to logLinks, not logMessages
  • Added "logFailures" (settings.channels[].logLinks.logFailures), only applies to logLinks, not logMessages
  • divideFoldersByChannel now includes category name if available
  • Added "messageOutput" (settings.messageOutput) to disable message logging in the console, true by default.
  • Userbot message fixing now accounts for embeds
  • Now checks validity of sources (channels/servers) upon launch to troubleshoot issues
  • Fixed issues with emoji command
  • Fixed "InvalidFilename" issue
  • Better status message formatting for history command
  • Made slight efficiency tweaks
discord-downloader-go -

Published by get-got over 3 years ago

  • Fixed issues that caused adminChannels to not listen for commands properly
  • Fixed issue that caused Instagram files to not be downloaded correctly
    • It currently won't use the proper shortcode & username for filename and sometimes has issues detecting the actual filetype, will work on it in the future.
  • Fixed issue that caused crashing relating to embed colors
  • Added setting for "adminChannels":
    • "unlockCommands" (bool) - Unrestrict admin commands so anyone can use within this admin channel, false by default.
  • Added "filters" settings group for channels/servers/all:
    • All are optional
    • "blockedPhrases" (list of strings) - List of phrases to make the bot ignore this message. Will ignore any message containing a blocked phrase UNLESS it also has an allowed phrase. Messages will be processed by default.
    • "allowedPhrases" (list of strings) - List of phrases to allow the bot to process the message.
    • "blockedUsers" (list of strings) - Will ignore messages from the following users.
    • "allowedUsers" (list of strings) - Will ONLY process messages if they were sent from the following users.
    • "blockedRoles" (list of strings) - Will ignore messages from users with any of the following roles.
    • "allowedRoles" (list of strings) - Will ONLY process messages if they were sent from users with any of the following roles.
    • "blockedExtensions" (list of strings) - List of file extensions for the bot to ignore (include periods).
    • "allowedExtensions" (list of strings) - Will ONLY process files if they have the following extensions (include periods).
    • "blockedDomains" (list of strings) - List of file source domains (websites) for the bot to ignore.
    • "allowedDomains" (list of strings) - Will ONLY process files if they were sent from any of the following domains (websites).
  • Added "logLinks" & "logMessages" settings groups for channels/servers/all:
    • Only "destination" is required, the rest are optional or default
    • "destination" (string) - Filepath for single log file to be stored, or directory path for multiple logs to be stored.
    • "destinationIsFolder" (bool) - true if "destination" above is for a directory for multiple logs, false by default.
    • "divideLogsByServer" (bool) - ONLY USED IF "destinationIsFolder" ABOVE IS true; Separates log files by Server ID, true by default.
    • "divideLogsByChannel" (bool) - ONLY USED IF "destinationIsFolder" ABOVE IS true; Separates log files by Channel ID, true by default.
    • "divideLogsByUser" (bool) - ONLY USED IF "destinationIsFolder" ABOVE IS true; Separates log files by User ID, false by default.
    • "filterDuplicates" (bool) - Filters out duplicate links (or messages) from being logged if already present in log file.
    • "prefix" (string) - Prepend log line with string.
    • "suffix" (string) - Append log line with string.
    • "userData" (bool) - Include additional data such as SERVER/CHANNEL/USER ID's for logged files/messages. false by default.
  • Removed settings from channels/servers/all
    • "extensionBlacklist" (list of strings), replaced with "filters"."blockedExtensions"
    • "domainBlacklist" (list of strings), replaced with "filters"."blockedDomains"
    • "usersAllWhitelisted" (bool), unnecessary
    • "userWhitelist" (list of strings), replaced with "filters"."allowedUsers"
    • "userBlacklist" (list of strings), replaced with "filters"."blockedUsers"
    • "saveAllLinksToFile" (bool), replaced with "logLinks"
  • Project icon is now monkey
  • Various improvements for quality of life, crash-avoidance, stability, etc
discord-downloader-go -

Published by get-got over 3 years ago

  • Added Constants for Settings (see top of List of Settings in readme)
  • Added "logStatus" and "logErrors" to adminChannels settings: Bot will send status messages to admin channel(s) upon launch or reconnection and error messages for download failures. Both are optional and true by default.
  • Fixed issue that made some channels ignore all files unless user was bot admin
  • Fixed autorunHistory issues that made it not account for channels within registered servers and caused crashes
  • Made history command accept Server ID(s) as arguments instead of just Channel ID(s)
  • Fixed crashing issue with commands, added more debug/error logging
  • Added "discordLogLevel" to main settings, for discordgo (0 = Errors, 1 = Warnings, 2 = Info, 3 = Debug)
  • Made logging output bound servers
  • Presence Key Changes: {{numGuilds}} renamed to {{numServers}}, {{numChannels}} renamed to {{numBoundChannels}}, {{numBoundServers}} added
discord-downloader-go -

Published by get-got over 3 years ago

  • Added "servers" configurations for downloading based upon server ID(s). Follows same layout as "channels" section, except uses "server" instead of "channel" and "servers" instead of "channels"
  • Renamed "allChannels" to "all"
  • Added "allBlacklistServers"
  • Renamed "allChannelsBlacklist" to "allBlacklistChannels"
  • Fixed importing "[twitter] access token secret" from discord-image-downloader-go's config.ini
  • Outputs more details when failing to download
  • Checks validity of directory & file paths more when downloading
  • Updated some miscellaneous dependencies
discord-downloader-go -

Published by get-got over 3 years ago

  • Workaround/Fix for empty message issue (Discord blocking endpoints) for userbots/selfbots.
discord-downloader-go -

Published by get-got over 3 years ago

  • Reworked ddg history command... Argument/Flag order no longer matters; Adds --since= and --before= flags (see README in History section) to limit range by YYYY-MM-DD date or Message ID; Adds stop as alternative to cancel
  • Added ddg info command for outputting Discord ID's
  • Added asyncHistory (bool, false by default) to run history cataloging asynchronously (simultaneously)
  • Added checkPermissions (bool, true by default) setting to disable permission checks if encountering issues
  • Improved savePossibleDuplicates to allow duplicate URL downloading.
  • Fixed History not working for some channels
  • Improved download consistency for History command
  • Fixed download counter in History status message
  • Cleaned up some output/logging
  • Made typeWhileProcessing false by default due to some rare crashing issue
  • Supports alternate Mastodon URL format
  • Moved save location for history progress cache & duplicate image cache
  • Updated dependencies (excluding discordgo)
discord-downloader-go -

Published by get-got over 3 years ago

  • Added support for Mastodon posts! (Please let me know if there's any issues)
  • Added all modifier to history command to process history for all registered channels via single command. (Use as ddg history all in admin channel).
  • Added emojis command for saving all of a servers emojis. Use as ddg emojis within registered or admin channels to download from that server, or use as ddg emojis SERVER_ID / ddg emojis SERVER_ID_1, SERVER_ID_2, SERVER_ID_3 in an admin channel to download emojis from a different server.
  • Fixed some files being ignored due to file extension being missing in url.
  • Added ignoreBots (bool) setting to main settings area to allow bot to ignore messages from other bots. Default is false.
  • Fixed saveAllLinksToFile not applying to history processing
  • Fixed messed up history log formatting
  • Minor appearance/logging tweaks
discord-downloader-go -

Published by get-got over 3 years ago

  • allChannels setting allows you to let the bot listen to any and every channel it has access to, following the settings in allChannels (it's the same as channels settings, just without Channel ID(s)). allChannelsBlacklist is an optional array of strings that allows you to block specific channels from this (using Channel ID(s)).
  • Shows typing when processing things that take a while; Optional: typeWhileProcessing (bool)
  • Improved importing of Sekl's config
  • Bot attempts to reconnect when it detects it's no longer connected to Discord
  • URLs/Domains are validated now to prevent crashing when processing messages that contain incorrect URLs
discord-downloader-go -

Published by get-got over 3 years ago

  • Reddit post/thread media support (can only source media from the main post, notify me if anything is broken)
  • When initializing settings for the first time, if a config.ini from Sekl's project is present it will import into this projects JSON settings.
  • Settings does not require backslashes to be escaped (previously needed to replace all \ with \\)
  • Release builds now include macOS binaries (no idea if it completely works, is meant to be executed via Terminal)
  • Docker image builds for releases and live development are now available (please notify me if anything works improperly)
discord-downloader-go -

Published by get-got almost 4 years ago

  • Fixed permission issue that prevented commands from working in DMs and Group DMs.
discord-downloader-go -

Published by get-got almost 4 years ago

  • Added live updating for settings, improved stability of settings decoding.
  • Added Discord permission checks for all(?) Discord actions to avoid crashing (checks for proper permission to send messages prior to attempting, checks for reaction permission prior to attempting, etc).
  • Fixed permission issue with download folders created by bot.
  • Made bot ignore wsapi error when doing user login.
  • Improved source naming for Direct Messages & Group Messages.
discord-downloader-go -

Published by get-got almost 4 years ago

  • History cataloging now records progress to later resume if interrupted or stopped without having to catch up to prior progress
  • Fixed history autorun crashing when bot lacks discord permissions
discord-downloader-go -

Published by get-got almost 4 years ago

  • Added autorunHistory (global) and overwriteAutorunHistory (channels) for running history cataloging upon program launch/login.
  • Fixed and Improved numerous parts of history cataloging & logging.
  • Fixed presence details showing wrong day in date.
  • Added numberFormatEuropean option (bool) for formatting numbers as 123.456,78 rather than 123,456.78
  • Removed Support for Facebook Videos; they changed how it works and I don't see an easy way to remedy it, currently.
  • Reduced some clutter with download logging.
discord-downloader-go -

Published by get-got almost 4 years ago

  • Improved filename dating so it actually names based upon time of message, not time of download
  • Added userBot to the config credentials section, set to true if using a user bot with 2FA for token login to work properly
  • Fixed history command usage within DM channels
  • Fixed scanOwnMessages so it actually works when cataloging message history
  • Fixed problem where help command was unintentionally running
discord-downloader-go -

Published by get-got almost 4 years ago

  • Fixed an issue where files like .mov were unintentionally ignored
  • Improved history cataloging efficiency and status updates
  • Fixed Presence so presenceStatus can be set while presenceEnabled is false, to just set status (online,idle,invisible) with no additional details
  • Fixed filename issue for files with extensions more than 4 characters
discord-downloader-go -

Published by get-got almost 4 years ago

  • Added divideFoldersByServer, nests downloads within a subfolder of destination based upon server name of origin.
  • Added divideFoldersByChannel, nests downloads within a subfolder of destination based upon channel name of origin.
  • Added divideFoldersByUser, nests downloads within a subfolder of destination based upon user who sent content.
  • Fixed destination folder permission issue.
  • Made Image Duplicate Filter exclude .gif and .webp to avoid errors.
discord-downloader-go -

Published by get-got almost 4 years ago

  • Fixed Reactions for using bot in DM Channels
  • Fixed Fatal Error with Image Duplicate Filter that would cause crashing on reboot and large imgStore file size (because I'm dumb)
discord-downloader-go -

Published by get-got almost 4 years ago

  • (Experimental) Duplicate Filtering - add filterDuplicates to the main configuration and set it to true. This will attempt to match images up to each other to prevent duplicates from being saved (even if they've been deepfried or have different filenames). You can adjust the similarity threshold via filterDuplicatesThreshold (float64; a number with a decimal, see README for info).
  • Multi-Channel Configurations - use channels instead of channel within each channel configuration to make that configuration apply to an unlimited amount of channels simultaneously, without needing to copy/paste the same thing over and over again.
  • Lots of efficiency & cleanup stuff that doesn't matter for users
discord-downloader-go -

Published by get-got almost 4 years ago

  • Added userBlacklist for channels to block specific users from having their messages checked for files.
  • Added userWhitelist and usersAllWhitelisted for channels to only allow files to be downloaded from specific users.
  • Added domainBlacklist for channels to block files from specified domains from being downloaded.
  • Added saveAllLinksToFile for channels. Will save all raw links to specified text file, no filtering or parsing whatsoever.
  • Fixed issue where program would crash during history cataloging if bot did not have Send Messages permission for channel.
  • Changed blacklistedExtensions to extensionBlacklist. If you have a definition for this in your settings you will need to change it.
  • Added space to end of filenameDateFormat, rather than having it hard-coded into the filename creation (so you can use an underscore or whatever instead).
  • Changed default order of some general settings. The order should not effect existing configurations, as configuration is name/key based.
discord-downloader-go -

Published by get-got almost 4 years ago

  • Adds Google Drive Support (ported from Seklfreak's original project)

  • Adds Tistory Support (ported from Seklfreak's original project)

Package Rankings
Top 8.17% on Proxy.golang.org