Skip to main content
Glama
Dan8Oren

mcp-apple-notes

delete-note

Delete an Apple Note by moving it to Recently Deleted. Identify the note by noteId or title, and use the optional folder path to disambiguate duplicate titles.

Instructions

Delete an Apple Note (moves to Recently Deleted). Identify note by noteId or title.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
noteIdNoApple Notes ID. If provided, skips title resolution.
titleNoTitle of the note to delete
pathNoOptional folder path to disambiguate duplicate titles

Implementation Reference

  • The actual delete-note handler function. It uses JXA (JavaScript for Automation) to find the note by ID in Apple Notes and calls app.delete() to move it to Recently Deleted.
    const deleteNote = async (noteId: string) => {
      await verboseRunJxa(
        `const app = Application('Notes');
        const noteId = args[0];
        const note = Array.from(app.notes()).find(note => {
          return note.id() === noteId;
        });
        if (!note) throw new Error('__NOTE_NOT_FOUND__:' + noteId);
        app.delete(note);
        return true;`,
        [noteId]
      );
    };
  • Zod schema for delete-note input validation. Accepts optional noteId, title, and path strings; requires at least noteId or title.
    const DeleteNoteSchema = z
      .object({
        noteId: z.string().optional(),
        title: z.string().optional(),
        path: z.string().optional(),
      })
      .refine((d) => d.noteId || d.title, { message: "Either noteId or title must be provided" });
  • index.ts:352-371 (registration)
    Tool registration in the list of all tools. The delete-note tool is defined with name 'delete-note', description, and input schema referencing noteId, title, and path.
    {
      name: "delete-note",
      description:
        "Delete an Apple Note (moves to Recently Deleted). Identify note by noteId or title.",
      inputSchema: {
        type: "object",
        properties: {
          noteId: {
            type: "string",
            description: "Apple Notes ID. If provided, skips title resolution.",
          },
          title: { type: "string", description: "Title of the note to delete" },
          path: {
            type: "string",
            description: "Optional folder path to disambiguate duplicate titles",
          },
        },
        required: [],
      },
    },
  • The CallToolRequestSchema handler that dispatches to deleteNote. It parses args with DeleteNoteSchema, resolves the note via resolveNoteId, calls deleteNote to delete it, removes it from the index, and returns a success response.
    } else if (name === "delete-note") {
      const { noteId, title, path } = DeleteNoteSchema.parse(args);
      const { note: resolvedNote } = await resolveNoteId(notesTable, noteId, title, path);
      await deleteNote(resolvedNote.id);
      await removeIndexedNoteById(notesTable, resolvedNote.id);
      return createJsonResponse({
        ok: true,
        data: { id: resolvedNote.id, title: resolvedNote.title, path: resolvedNote.path },
        message: `Deleted note "${resolvedNote.title}".`,
      });
  • index.ts:17-23 (registration)
    Registration in the MUTATING_TOOLS set, which controls whether the tool is available in read-only mode.
    const MUTATING_TOOLS = new Set([
      "create-note",
      "edit-note",
      "append-to-note",
      "move-note",
      "delete-note",
    ]);
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description must disclose behavioral traits. It reveals the key behavior: the note is moved to Recently Deleted (soft delete). However, it does not mention if the operation is reversible, any permission requirements, or side effects on attachments or metadata.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single sentence that packs action, side effect, and identification method without any extraneous words. It is front-loaded and efficient.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no output schema, the description covers the core functionality and identification. It does not describe the return format or error handling, but for a delete operation, the information is reasonably complete for an agent.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100% with descriptions for all three parameters. The description adds context that noteId skips title resolution and path is for disambiguation, providing marginal value beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action (delete) and the resource (Apple Note), and specifies the side effect (moves to Recently Deleted). It distinguishes from sibling tools like edit-note or create-note.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage by identifying the note via noteId or title, and mentions disambiguation with folder path. However, no explicit guidance on when to use this vs. alternatives like move-note (which might also modify note state) or when not to use it.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/Dan8Oren/mcp-apple-notes'

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