generate functionMon, 14 Nov 2022

Send the data in hookah.txt to a discord channel.

import json import requests def send_hookah_data(): with open('hookah.txt') as file: data = json.load(file) payload = {'content': 'This is some text.'} r = requests.post('https://discordapp.com/api/webhooks/123/456', json=payload)

Questions about programming?Chat with your personal AI assistant