1-0-1-Labs / discord_parser

parsing info from discord, wallet addresses etc.
2 stars 0 forks source link

parse solana addresses from discord channel #1

Closed selimerunkut closed 2 years ago

selimerunkut commented 2 years ago

Given a discord server and channel, parse the discord ids and solana addresses from it. Write the results into a json file .

json format: {"discord_id":"", "wallet_address":""}

production server: https://discord.gg/zURQN3YR

test server: https://discord.gg/DSNqwknU

selimerunkut commented 2 years ago

@0x471 instead of writing into the script itself read config vars from a .env file (https://pypi.org/project/python-dotenv/)

token = 'DISCORD_BOT_TOKEN'  # Auth token of the discord bot
channel_id = "CHANNEL ID AS AN INTEGER"  # Discord channel id which is for parsing
regexp = "[1-9A-HJ-NP-Za-km-z]{32,44}"  # Solana wallet addr regexp
json_filepath = "JSON_FILEPATH"  # Filepath for dumping json data