summaryrefslogtreecommitdiff
path: root/backend/src/types/robot.ts
diff options
context:
space:
mode:
Diffstat (limited to 'backend/src/types/robot.ts')
-rw-r--r--backend/src/types/robot.ts20
1 files changed, 20 insertions, 0 deletions
diff --git a/backend/src/types/robot.ts b/backend/src/types/robot.ts
new file mode 100644
index 0000000..40ce282
--- /dev/null
+++ b/backend/src/types/robot.ts
@@ -0,0 +1,20 @@
+export type RobotPosition = {
+ lat: number;
+ lon: number;
+};
+
+export type Robot = {
+ id: number;
+ name: string;
+ status: "idle" | "moving";
+ lat: number;
+ lon: number;
+ robot_positions: RobotPosition[];
+ created_at: string;
+ updated_at: string;
+};
+
+export type RobotsResponse = {
+ source: "cache" | "database";
+ data: Robot[];
+};