OSS-first docs
These docs teach the open system first: contracts, generated surfaces, runtimes, governance, and incremental adoption. Studio shows up as the operating layer on top, not as the source of truth.
Removes a tool assignment from an agent.
Goal
Disable specific tools for an agent.
Context
Agent configuration UI - tool management.
Source Definition
import {
defineCommand,
defineQuery,
} from '@lssm-tech/lib.contracts-spec/operations';
import { defineSchemaModel, ScalarTypeEnum } from '@lssm-tech/lib.schema';
import { AgentStatusEnum, ModelProviderEnum } from './agent.enum';
import { AgentCreatedEvent } from './agent.event';
import {
AgentSummaryModel,
AgentWithToolsModel,
CreateAgentInputModel,
UpdateAgentInputModel,
} from './agent.schema';
export const RemoveToolFromAgentCommand = defineCommand({
meta: {
key: 'agent-console.agent.removeTool',
version: '1.0.0',
stability: 'stable',
owners: ['@agent-console-team'],
tags: ['agent', 'tool', 'remove'],
description: 'Removes a tool assignment from an agent.',
goal: 'Disable specific tools for an agent.',
context: 'Agent configuration UI - tool management.',
},
io: {
input: defineSchemaModel({
name: 'RemoveToolFromAgentInput',
fields: {
agentId: { type: ScalarTypeEnum.String_unsecure(), isOptional: false },
toolId: { type: ScalarTypeEnum.String_unsecure(), isOptional: false },
},
}),
output: defineSchemaModel({
name: 'RemoveToolFromAgentOutput',
fields: {
success: { type: ScalarTypeEnum.Boolean(), isOptional: false },
},
}),
},
policy: { auth: 'user' },
sideEffects: { audit: ['agent.tool.removed'] },
acceptance: {
scenarios: [
{
key: 'remove-tool-happy-path',
given: ['Agent exists', 'Tool is assigned to agent'],
when: ['User removes tool from agent'],
then: ['Tool is unassigned', 'Success is returned'],
},
],
examples: [
{
key: 'remove-basic',
input: { agentId: 'agent-123', toolId: 'tool-456' },
output: { success: true },
},
],
},
});