Press n or j to go to the next uncovered block, b, p or k for the previous block.
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 | import { Controller, Get } from '@nestjs/common'; import { ApiTags, ApiOperation, ApiResponse } from '@nestjs/swagger'; import { AppService } from './app.service'; @ApiTags('Health Check') @Controller() export class AppController { constructor(private readonly appService: AppService) {} @Get() @ApiOperation({ summary: 'Health check endpoint' }) @ApiResponse({ status: 200, description: 'API is running successfully', schema: { type: 'object', properties: { message: { type: 'string' }, timestamp: { type: 'string' }, version: { type: 'string' }, environment: { type: 'string' }, }, }, }) getHealth() { return this.appService.getHealth(); } @Get('status') @ApiOperation({ summary: 'Detailed system status' }) @ApiResponse({ status: 200, description: 'Detailed system status information', }) getStatus() { return this.appService.getStatus(); } } |