Skip to main content
Glama

favourite_manga

Manage your manga favorites on AniList by adding or removing titles using their unique ID. Requires login to update your preferences.

Instructions

[Requires Login] Favourite or unfavourite a manga by its ID

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesThe AniList ID of the manga to favourite/unfavourite

Implementation Reference

  • The handler function that implements the core logic of the 'favourite_manga' tool. It authenticates the user via requireAuth, toggles the favourite status of the specified manga ID using the AniList API, and returns a textual response indicating success or failure.
    async ({ id }) => {
      try {
        const auth = requireAuth(config.anilistToken);
        if (!auth.isAuthorized) {
          return auth.errorResponse;
        }
    
        const result = await anilist.media.favouriteManga(id);
        return {
          content: [
            {
              type: "text",
              text: result
                ? `Successfully added manga with ID ${id} to favourites.`
                : `Manga with ID ${id} was removed from favourites or operation failed.`,
            },
          ],
        };
      } catch (error: any) {
        return {
          content: [{ type: "text", text: `Error: ${error.message}` }],
          isError: true,
        };
      }
    },
  • The input schema for the 'favourite_manga' tool, defining a required numeric 'id' parameter for the AniList manga ID.
    {
      id: z
        .number()
        .describe("The AniList ID of the manga to favourite/unfavourite"),
    },
  • tools/media.ts:110-150 (registration)
    The registration of the 'favourite_manga' tool with the MCP server, including name, description, input schema, tool hints, and handler function.
    server.tool(
      "favourite_manga",
      "[Requires Login] Favourite or unfavourite a manga by its ID",
      {
        id: z
          .number()
          .describe("The AniList ID of the manga to favourite/unfavourite"),
      },
      {
        title: "Favourite/Unfavourite Manga",
        readOnlyHint: false,
        destructiveHint: true,
        idempotentHint: false,
        openWorldHint: true,
      },
      async ({ id }) => {
        try {
          const auth = requireAuth(config.anilistToken);
          if (!auth.isAuthorized) {
            return auth.errorResponse;
          }
    
          const result = await anilist.media.favouriteManga(id);
          return {
            content: [
              {
                type: "text",
                text: result
                  ? `Successfully added manga with ID ${id} to favourites.`
                  : `Manga with ID ${id} was removed from favourites or operation failed.`,
              },
            ],
          };
        } catch (error: any) {
          return {
            content: [{ type: "text", text: `Error: ${error.message}` }],
            isError: true,
          };
        }
      },
    );
Behavior2/5

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

No annotations are provided, so the description carries full burden. It mentions a login requirement, which is useful, but doesn't disclose other behavioral traits such as whether this is a toggle action (favourite/unfavourite), potential side effects (e.g., updating user lists), rate limits, or error conditions. The description is minimal and lacks depth for a mutation tool.

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 extremely concise with two parts: a prerequisite in brackets and the core action, all in one sentence. It's front-loaded with the login requirement and wastes no words, making it efficient and easy to parse.

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

Completeness2/5

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

Given that this is a mutation tool with no annotations, no output schema, and minimal description, it lacks completeness. The description covers the basic action and login need but omits details on behavior (e.g., toggle nature), response format, or error handling, leaving gaps for an AI agent to understand full usage.

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 description coverage is 100%, with the parameter 'id' fully documented in the schema as 'The AniList ID of the manga to favourite/unfavourite'. The description doesn't add any additional meaning beyond this, so it meets the baseline of 3 where the schema handles parameter documentation adequately.

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

Purpose4/5

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

The description clearly states the action ('favourite or unfavourite') and resource ('a manga by its ID'), making the purpose specific and understandable. However, it doesn't explicitly differentiate from sibling tools like 'favourite_anime' or 'favourite_character' beyond specifying 'manga', which is implied but not contrasted.

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 includes '[Requires Login]' which provides context on prerequisites, but it doesn't specify when to use this tool versus alternatives (e.g., when to favourite vs. unfavourite, or how it relates to other favourite tools). Usage is implied through the action, but no explicit guidance on scenarios or exclusions is given.

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

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

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