import { Injectable } from '@nestjs/common';

export interface RuntimeVersion {
  service: 'server';
  version: string;
  buildTime: string;
  imageTag: string;
}

@Injectable()
export class HealthService {
  getVersion(): RuntimeVersion {
    return {
      service: 'server',
      version: process.env.APP_VERSION || 'unknown',
      buildTime: process.env.APP_BUILD_TIME || '',
      imageTag: process.env.APP_IMAGE_TAG || '',
    };
  }
}
