diff --git a/assets/snack-time.jpg b/assets/snack-time.jpg new file mode 100644 index 0000000..b4ddf00 Binary files /dev/null and b/assets/snack-time.jpg differ diff --git a/main.py b/main.py index 66e7cfd..b85f6e4 100644 --- a/main.py +++ b/main.py @@ -87,7 +87,14 @@ def main () -> None: has_got_snack_time = False if now.hour == 15 and not has_got_snack_time: - client.send_post (Talk.main ('おやつタイムだ!!!!')) + with open ('./assets/snack-time.jpg', 'rb') as f: + image = models.AppBskyEmbedImages.Image ( + alt = 'おやつタイムだ!!!!', + image = client.com.atproto.repo.upload_blob (f).blob) + + client.send_post (Talk.main ('おやつタイムだ!!!!'), + embed = models.app.bsky.embed.images.Main ( + images = [image])) last_posted_at = now has_got_snack_time = True