@@ -31,6 +31,10 @@ export class GetNativeAgentConfigurationDto {
}
export class SaveNativeAgentConfigurationDto {
+ @IsString()
+ @IsNotEmpty({ message: 'user不能为空' })
+ user: string
+
@IsNumber()
@IsOptional()
agentId?: number
@@ -39,6 +39,7 @@ export class AgentListController {
@Body() body: SaveNativeAgentConfigurationDto
) {
return this.agentListService.saveNativeAgentConfiguration({
+ user: body.user,
agent_id: body.agentId,
name: body.name,
display_name: body.displayName,
@@ -24,6 +24,7 @@ type AgentConfigurationType = {
type SaveAgentConfigurationType = {
agent_id?: number
name: string
display_name?: string