create_project_note
Add notes to Autotask projects to document progress, tasks, or updates for team collaboration and project tracking.
Instructions
Create a new note for a project
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| projectId | Yes | The project ID to add the note to | |
| title | No | Note title | |
| description | Yes | Note content | |
| noteType | No | Note type (1=General, 2=Appointment, 3=Task, 4=Ticket, 5=Project, 6=Opportunity) |
Implementation Reference
- src/handlers/tool.handler.ts:592-617 (registration)Registers the 'create_project_note' tool with name, description, and input schema in the listTools() method.{ name: 'create_project_note', description: 'Create a new note for a project', inputSchema: { type: 'object', properties: { projectId: { type: 'number', description: 'The project ID to add the note to' }, title: { type: 'string', description: 'Note title' }, description: { type: 'string', description: 'Note content' }, noteType: { type: 'number', description: 'Note type (1=General, 2=Appointment, 3=Task, 4=Ticket, 5=Project, 6=Opportunity)' } }, required: ['projectId', 'description'] } },
- src/handlers/tool.handler.ts:1205-1212 (handler)Handles the tool execution in callTool() by delegating to autotaskService.createProjectNote with parsed arguments.case 'create_project_note': result = await this.autotaskService.createProjectNote(args.projectId, { title: args.title, description: args.description, noteType: args.noteType }); message = `Successfully created project note with ID: ${result}`; break;
- Core implementation that creates the project note via the Autotask client.notes.create() API call, attaching it to the specified project.async createProjectNote(projectId: number, note: Partial<AutotaskProjectNote>): Promise<number> { const client = await this.ensureClient(); try { this.logger.debug(`Creating project note for project ${projectId}:`, note); const noteData = { ...note, projectId: projectId }; const result = await client.notes.create(noteData as any); const noteId = (result.data as any)?.id; this.logger.info(`Project note created with ID: ${noteId}`); return noteId; } catch (error) { this.logger.error(`Failed to create project note for project ${projectId}:`, error); throw error; } }