Initial commit: Set up Garmin Health Lab project structure
- Initialize monorepo with root workspace configuration - Set up Express.js backend with TypeScript - Set up React 18 frontend with TypeScript - Create database schema with SQLite - Implement project architecture and documentation - Add development and deployment guidelines Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
This commit is contained in:
59
server/src/types/index.ts
Normal file
59
server/src/types/index.ts
Normal file
@@ -0,0 +1,59 @@
|
||||
export interface User {
|
||||
id: string;
|
||||
email: string;
|
||||
garminEmail: string;
|
||||
createdAt: Date;
|
||||
updatedAt: Date;
|
||||
}
|
||||
|
||||
export interface HealthData {
|
||||
id: string;
|
||||
userId: string;
|
||||
date: Date;
|
||||
steps: number;
|
||||
heartRate?: number;
|
||||
heartRateVariability?: number;
|
||||
bloodPressure?: {
|
||||
systolic: number;
|
||||
diastolic: number;
|
||||
};
|
||||
sleep?: {
|
||||
duration: number;
|
||||
quality: number;
|
||||
};
|
||||
stress?: number;
|
||||
caloriesBurned?: number;
|
||||
createdAt: Date;
|
||||
updatedAt: Date;
|
||||
}
|
||||
|
||||
export interface Activity {
|
||||
id: string;
|
||||
userId: string;
|
||||
activityType: string;
|
||||
startTime: Date;
|
||||
endTime: Date;
|
||||
duration: number;
|
||||
distance?: number;
|
||||
calories?: number;
|
||||
heartRateAverage?: number;
|
||||
heartRateMax?: number;
|
||||
createdAt: Date;
|
||||
}
|
||||
|
||||
export interface HealthRecommendation {
|
||||
id: string;
|
||||
userId: string;
|
||||
category: string;
|
||||
recommendation: string;
|
||||
priority: 'high' | 'medium' | 'low';
|
||||
basedOn: string[];
|
||||
createdAt: Date;
|
||||
}
|
||||
|
||||
export interface SyncStatus {
|
||||
lastSyncTime: Date;
|
||||
status: 'idle' | 'syncing' | 'error';
|
||||
lastError?: string;
|
||||
recordsSynced: number;
|
||||
}
|
||||
Reference in New Issue
Block a user