Skip to main content
Glama

remove_list_entry

Remove an entry from your AniList account by specifying its list ID. Use this tool to manage your anime or manga list efficiently, requiring a valid login for access.

Instructions

[Requires Login] Remove an entry from the authorized user's list

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesThe AniList list ID of the entry to remove

Implementation Reference

  • tools/lists.ts:118-156 (registration)
    Registration of the 'remove_list_entry' tool using server.tool(). Includes inline input schema (id: number), metadata, and the handler function that authenticates, calls anilist.lists.removeEntry(id), and returns success/error response.
    server.tool(
      "remove_list_entry",
      "[Requires Login] Remove an entry from the authorized user's list",
      {
        id: z.number().describe("The AniList list ID of the entry to remove"),
      },
      {
        title: "Remove List Entry",
        readOnlyHint: false,
        destructiveHint: true,
        idempotentHint: true,
        openWorldHint: true,
      },
      async ({ id }) => {
        try {
          const auth = requireAuth(config.anilistToken);
          if (!auth.isAuthorized) {
            return auth.errorResponse;
          }
    
          const result = await anilist.lists.removeEntry(id);
          return {
            content: [
              {
                type: "text",
                text: result
                  ? `Successfully removed list entry with ID ${id}.`
                  : `Failed to remove list entry with ID ${id}.`,
              },
            ],
          };
        } catch (error: any) {
          return {
            content: [{ type: "text", text: `Error: ${error.message}` }],
            isError: true,
          };
        }
      },
    );
  • The inline handler function for 'remove_list_entry' tool. Performs authentication check, removes the list entry using the AniList client, and formats the response.
    async ({ id }) => {
      try {
        const auth = requireAuth(config.anilistToken);
        if (!auth.isAuthorized) {
          return auth.errorResponse;
        }
    
        const result = await anilist.lists.removeEntry(id);
        return {
          content: [
            {
              type: "text",
              text: result
                ? `Successfully removed list entry with ID ${id}.`
                : `Failed to remove list entry with ID ${id}.`,
            },
          ],
        };
      } catch (error: any) {
        return {
          content: [{ type: "text", text: `Error: ${error.message}` }],
          isError: true,
        };
      }
    },
  • Input schema for the 'remove_list_entry' tool, requiring a numeric 'id' parameter representing the AniList list entry ID.
    {
      id: z.number().describe("The AniList list ID of the entry to remove"),
    },

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/yuna0x0/anilist-mcp'

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