import { Controller , Get } from '@nestjs/common' ; import { EmailService } from './email.service' ; @ Controller ( 'email' ) export class EmailController { constructor ( private readonly emailService ) { } @ Get ( ) sendEmail ( ) { this . emailService . sendEmail ( ) ; return 'Message sent' ; } }