From 96f40b45cf1dc598b058b31eb7b03481882b7fc1 Mon Sep 17 00:00:00 2001 From: Dennis Chen Date: Wed, 5 Jun 2024 17:47:07 -0700 Subject: [PATCH] forgot to ad --- store/app/api/crud/robots.py | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 store/app/api/crud/robots.py diff --git a/store/app/api/crud/robots.py b/store/app/api/crud/robots.py new file mode 100644 index 00000000..357f3c64 --- /dev/null +++ b/store/app/api/crud/robots.py @@ -0,0 +1,10 @@ +"""Defines CRUD interface for robot API.""" + +from store.app.api.crud.base import BaseCrud +from store.app.api.model import Robot + + +class RobotCrud(BaseCrud): + async def add_robot(self, robot: Robot) -> None: + table = await self.db.Table("Robots") + await table.put_item(Item=robot.model_dump())