53
loading...
This website collects cookies to deliver better user experience
If you already have a discord server created and a channel ready, you can skip this step and jump to the "Create a Discord Webhook" section.
$ mkdir my-project
$ cd ~/Desktop/my-project && pip3 install -t . discord-webhook
$ rm -r *dist-info __pycache__
rm: __pycache__: No such file or directory
At the time of this writing, the current version of discord-webhook is 0.14.0.
$ zip -r -q ~/Desktop/my-project.zip .
webhook = DiscordWebhook(url="<replace_with_your_hook>")
embed = DiscordEmbed(
title="Taco Love",
description="You deserve some taco love today!",
color="03b2f8")
embed.set_image(url="https://cdn.dribbble.com/users/545781/screenshots/3157610/happy-taco.jpg")
webhook.add_embed(embed)
webhook.execute()
def lambda_handler(event, context):
return {
"statusCode": 200,
"body": {"message": "Hello World"}
}