- In Slack, click on Tools -> Customize Workspace
- Open up your network tab and filter for
emoji.admin - Scroll the full list
- Open up the response from each
emoji.adminJSON request that was made and copy it to apage-*.jsonfile - In a terminal, run
slack-emoji-download.sh page-1.jsonto download every emoji listed in that page to anoutputdirectory. - Continue until you have every emoji donwloaded.
Last active
November 15, 2025 00:13
-
-
Save erunion/7464da10e8b47d5064dcd0c16c2c38a5 to your computer and use it in GitHub Desktop.
simple script to backup emojis in slack
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| # Script to download emojis from a JSON file | |
| # Usage: ./download.sh page-1.json | |
| # Check if jq is installed | |
| if ! command -v jq &> /dev/null; then | |
| echo "Error: jq is required but not installed. Please install jq first." | |
| echo "On macOS: brew install jq" | |
| echo "On Ubuntu/Debian: sudo apt-get install jq" | |
| exit 1 | |
| fi | |
| # Check if input file is provided | |
| if [ -z "$1" ]; then | |
| echo "Usage: $0 <json-file>" | |
| exit 1 | |
| fi | |
| INPUT="$1" | |
| # Check if input file exists | |
| if [ ! -f "$INPUT" ]; then | |
| echo "Error: File '$INPUT' not found" | |
| exit 1 | |
| fi | |
| # Create output directory | |
| mkdir -p output | |
| # Counter for progress | |
| total=$(jq '.emoji | length' "$INPUT") | |
| current=0 | |
| echo "Found $total emojis to download" | |
| echo "" | |
| # Process each emoji in the JSON file | |
| jq -r '.emoji[] | "\(.name)|\(.url)"' "$INPUT" | while IFS='|' read -r name url; do | |
| current=$((current + 1)) | |
| # Skip if name or url is empty | |
| if [ -z "$name" ] || [ -z "$url" ]; then | |
| continue | |
| fi | |
| # Extract file extension from URL | |
| extension="${url##*.}" | |
| extension="${extension%%\?*}" # Remove query parameters if any | |
| # Default to .png if no extension found | |
| if [ -z "$extension" ] || [ "$extension" = "$url" ]; then | |
| extension="png" | |
| fi | |
| # Create filename | |
| filename="output/${name}.${extension}" | |
| # Download the file | |
| echo "[$current/$total] Downloading: $name" | |
| if curl -s -f -o "$filename" "$url"; then | |
| echo " ✓ Saved to: $filename" | |
| else | |
| echo " ✗ Failed to download: $name" | |
| fi | |
| done | |
| echo "" | |
| echo "Download complete!" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment