Skip to main content
Glama
Prototypr

Feedbagel MCP Server

Official
by Prototypr

search_feeds

Search a feed catalog by keyword to find feeds matching titles, URLs, or hostnames, returning up to 20 results with recency statistics.

Instructions

[read] Search the feed catalog by keyword. Matches feed titles, urls, and hostnames. Returns up to 20 results with recency stats.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYes

Implementation Reference

  • The handler function for the search_feeds tool. It extracts the 'query' parameter and makes a GET request to /api/v1/search-feeds/keyword/{query} on the FeedbagelClient instance.
    handler: ({ query }: any, c) =>
      c.request(
        "GET",
        `/api/v1/search-feeds/keyword/${encodeURIComponent(query)}`,
      ),
  • The input schema for search_feeds. Validates that 'query' is a string with length between 1 and 120 characters.
    inputSchema: z.object({
      query: z.string().min(1).max(120),
    }),
  • src/tools.ts:129-142 (registration)
    The full registration of the search_feeds tool in the TOOLS array. It defines the name, description, scope ('read'), inputSchema, and handler. The TOOLS array is imported by src/index.ts and used to list tools and dispatch tool calls.
    {
      name: "search_feeds",
      description:
        "Search the feed catalog by keyword. Matches feed titles, urls, and hostnames. Returns up to 20 results with recency stats.",
      scope: "read",
      inputSchema: z.object({
        query: z.string().min(1).max(120),
      }),
      handler: ({ query }: any, c) =>
        c.request(
          "GET",
          `/api/v1/search-feeds/keyword/${encodeURIComponent(query)}`,
        ),
    },
  • The FeedbagelClient helper class that provides the 'request' method used by the handler to make authenticated HTTP GET requests to the feedbagel API.
    export class FeedbagelClient {
      private apiKey: string;
      private baseUrl: string;
    
      constructor(opts: ClientOptions) {
        if (!opts.apiKey) throw new Error("FEEDBAGEL_API_KEY is required");
        this.apiKey = opts.apiKey;
        this.baseUrl = (opts.baseUrl ?? DEFAULT_BASE).replace(/\/$/, "");
      }
    
      async request(
        method: string,
        path: string,
        body?: unknown,
      ): Promise<unknown> {
        const res = await fetch(`${this.baseUrl}${path}`, {
          method,
          headers: {
            Authorization: `Bearer ${this.apiKey}`,
            ...(body !== undefined ? { "content-type": "application/json" } : {}),
          },
          body: body !== undefined ? JSON.stringify(body) : undefined,
        });
    
        const text = await res.text();
        let json: unknown = undefined;
        try {
          json = text ? JSON.parse(text) : undefined;
        } catch {
          json = { raw: text };
        }
    
        if (!res.ok) {
          // Surface 429 and 4xx details verbatim so the agent sees the cap info.
          const err: Error & { status?: number; body?: unknown } = new Error(
            `HTTP ${res.status} ${res.statusText}`,
          );
          err.status = res.status;
          err.body = json;
          throw err;
        }
        return json;
      }
    }
Behavior4/5

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

With no annotations, the description provides a clear [read] indicator, states result limits (up to 20), and mentions recency stats. It lacks details on rate limits or authentication, but is sufficient for a simple read operation.

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 two sentences, front-loads the action type '[read]', and contains no unnecessary words. Every sentence adds value.

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?

For a single-parameter search tool with no output schema, the description covers input semantics and output limits. It could mention sorting or pagination but is mostly complete.

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

Parameters4/5

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

Schema coverage is 0%, but the description adds meaning to the 'query' parameter by explaining it matches titles, urls, and hostnames. This compensates well for the missing schema descriptions.

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 verb 'Search', the resource 'feed catalog', and specifics about matching fields and output limits. It distinguishes from sibling 'search_feeds_by_url' by implying keyword search across multiple fields.

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 for keyword searches but does not explicitly state when to use this tool vs 'search_feeds_by_url' or other siblings. No exclusions or prerequisites are mentioned.

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/Prototypr/feedbagel-mcp'

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