Skip to main content
Glama

update_company

Modify company details in Autotask including contact information, address, and active status to maintain accurate client records.

Instructions

Update an existing company in Autotask

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
address1NoCompany address line 1
cityNoCompany city
companyNameNoCompany name
idYesCompany ID to update
isActiveNoWhether the company is active
phoneNoCompany phone number
postalCodeNoCompany postal/ZIP code
stateNoCompany state/province

Implementation Reference

  • Core handler implementation: Updates a company using the AutotaskClient.accounts.update API method.
    async updateCompany(id: number, updates: Partial<AutotaskCompany>): Promise<void> { const client = await this.ensureClient(); try { this.logger.debug(`Updating company ${id}:`, updates); await client.accounts.update(id, updates as any); this.logger.info(`Company ${id} updated successfully`); } catch (error) { this.logger.error(`Failed to update company ${id}:`, error); throw error; } }
  • MCP tool dispatcher: Handles 'update_company' tool calls by delegating to AutotaskService.updateCompany.
    case 'update_company': result = await this.autotaskService.updateCompany(args.id, args); message = `Successfully updated company ID: ${args.id}`; break;
  • Tool schema definition: Specifies input parameters, description, and validation for the update_company tool, provided via listTools().
    { name: 'update_company', description: 'Update an existing company in Autotask', inputSchema: { type: 'object', properties: { id: { type: 'number', description: 'Company ID to update' }, companyName: { type: 'string', description: 'Company name' }, phone: { type: 'string', description: 'Company phone number' }, address1: { type: 'string', description: 'Company address line 1' }, city: { type: 'string', description: 'Company city' }, state: { type: 'string', description: 'Company state/province' }, postalCode: { type: 'string', description: 'Company postal/ZIP code' }, isActive: { type: 'boolean', description: 'Whether the company is active' } }, required: ['id'] } },
  • MCP server registration: Registers the listTools handler which exposes the update_company tool schema to MCP clients.
    this.server.setRequestHandler(ListToolsRequestSchema, async () => { try { this.logger.debug('Handling list tools request'); const tools = await this.toolHandler.listTools(); return { tools }; } catch (error) { this.logger.error('Failed to list tools:', error); throw new McpError( ErrorCode.InternalError, `Failed to list tools: ${error instanceof Error ? error.message : 'Unknown error'}` ); } });

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/asachs01/autotask-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server