one_ton_daily_bot/client/src/main.ts

19 lines
529 B
TypeScript

import { NestFactory } from '@nestjs/core';
import { AppModule } from './app.module';
import { getBotToken } from 'nestjs-telegraf';
import * as express from 'express';
async function bootstrap() {
const app = await NestFactory.create(AppModule);
const bot = app.get(getBotToken());
console.log('Setting up webhook callback...');
app.use('/webhook', bot.webhookCallback());
app.use('/public', express.static('public'));
await app.listen(2000);
console.log('Application is running on port 2000');
}
bootstrap();