feat: implement command functionality with new CommandController, update Query entity, and enhance query execution with headers support
This commit is contained in:
@ -1,4 +1,4 @@
|
||||
import { Body, Controller, Inject, Param, Post } from "@nestjs/common";
|
||||
import { Body, Controller, Headers, Inject, Param, Post } from "@nestjs/common";
|
||||
import { QueryExecuterService } from "./query.executer.service";
|
||||
|
||||
@Controller("query")
|
||||
@ -11,8 +11,9 @@ export class QueryExecuterController {
|
||||
@Post("/run/:token")
|
||||
async runQuery(
|
||||
@Param("token") token: string,
|
||||
@Body() query: Record<string, any>
|
||||
@Body() query: Record<string, any>,
|
||||
@Headers() headers: Record<string, any>
|
||||
) {
|
||||
return this.queryExecuterService.runQuery(token, query);
|
||||
return this.queryExecuterService.runQuery(token, query, headers);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user