Add GET /i/:id/:secret hotlink image decrypt stream.

This commit is contained in:
2026-10-26 21:47:30 +01:00
parent 4517fe906a
commit 5db90f02c5
14 changed files with 696 additions and 4 deletions
+4 -2
View File
@@ -1,4 +1,4 @@
import { ValidationPipe } from '@nestjs/common';
import { RequestMethod, ValidationPipe } from '@nestjs/common';
import { ConfigService } from '@nestjs/config';
import { NestFactory } from '@nestjs/core';
import { NestExpressApplication } from '@nestjs/platform-express';
@@ -12,7 +12,9 @@ import { HttpMethod } from './types/HttpMethod';
async function bootstrap() {
const app = await NestFactory.create<NestExpressApplication>(AppModule, { bodyParser: false });
app.setGlobalPrefix('api');
app.setGlobalPrefix('api', {
exclude: [{ path: 'i/:id/:secret', method: RequestMethod.GET }]
});
const configService = app.get(ConfigService);
const altchaService = app.get(AltchaService);