import { All , Controller , Param , Req , Res } from '@nestjs/common' ; import { Request , Response } from 'express' ; import { Proxy , InjectProxy } from '@nestcloud/proxy' ; @ Controller ( '/proxy/:service' ) export class ProxyController { constructor ( @ InjectProxy ( ) private readonly proxy ) { } @ All ( ) async do ( @ Req ( ) req , @ Res ( ) res , @ Param ( 'service' ) id ) { return await this . proxy . forward ( req , res , id ) ; } }