Skip to main content
Glama
asachs01

Autotask MCP Server

get_ticket_note

Retrieve a specific note from an Autotask PSA ticket using ticket ID and note ID to access detailed ticket information.

Instructions

Get a specific ticket note by ticket ID and note ID

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
ticketIdYesThe ticket ID
noteIdYesThe note ID to retrieve

Implementation Reference

  • Defines the input schema, name, and description for the get_ticket_note tool used in MCP tool listing/registration
    {
      name: 'get_ticket_note',
      description: 'Get a specific ticket note by ticket ID and note ID',
      inputSchema: {
        type: 'object',
        properties: {
          ticketId: {
            type: 'number',
            description: 'The ticket ID'
          },
          noteId: {
            type: 'number', 
            description: 'The note ID to retrieve'
          }
        },
        required: ['ticketId', 'noteId']
      }
    },
  • Handler dispatch in callTool method that invokes the service method with parsed arguments
    case 'get_ticket_note':
      result = await this.autotaskService.getTicketNote(args.ticketId, args.noteId);
      message = `Ticket note retrieved successfully`;
  • Core implementation: Queries the Autotask notes.list API endpoint filtered by ticketId and noteId to retrieve the specific ticket note
    async getTicketNote(ticketId: number, noteId: number): Promise<AutotaskTicketNote | null> {
      const client = await this.ensureClient();
      
      try {
        this.logger.debug(`Getting ticket note - TicketID: ${ticketId}, NoteID: ${noteId}`);
        // Use generic notes endpoint with filtering
        const result = await client.notes.list({
          filter: [
            { field: 'ticketId', op: 'eq', value: ticketId },
            { field: 'id', op: 'eq', value: noteId }
          ]
        });
        const notes = (result.data as any[]) || [];
        return notes.length > 0 ? notes[0] as AutotaskTicketNote : null;
      } catch (error) {
        this.logger.error(`Failed to get ticket note ${noteId} for ticket ${ticketId}:`, error);
        throw 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