Browse Source

Picky, picky

Kirk Trombley 7 months ago
parent
commit
c968996049
1 changed files with 13 additions and 0 deletions
  1. 13 0
      commands/commands/querying.py

+ 13 - 0
commands/commands/querying.py

@@ -183,6 +183,19 @@ async def southie(req: Request, logger: Logger):
         RollbotFailure.SERVICE_DOWN.raise_exc(detail="Failed to call GOES16")
 
 
+@as_command
+async def seaboardie(req: Request, logger: Logger):
+    try:
+        async with req.get(
+            "https://cdn.star.nesdis.noaa.gov/GOES16/ABI/SECTOR/eus/GEOCOLOR/latest.jpg"
+        ) as res:
+            res.raise_for_status()
+            return Attachment("image", await res.read())
+    except:
+        logger.exception("Failed to call GOES16")
+        RollbotFailure.SERVICE_DOWN.raise_exc(detail="Failed to call GOES16")
+
+
 @as_command
 async def cat(req: Request, logger: Logger):
     """