Skip to main content
Glama
DumplingAI

Dumpling AI MCP Server

Official
by DumplingAI

extract-audio

Extract structured data from audio files using a prompt. Convert spoken content into organized information for analysis and processing.

Instructions

Extract structured data from audio files based on a prompt.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
inputMethodYesInput method
audioYesURL or base64-encoded audio
promptYesExtraction prompt
jsonModeNoReturn in JSON format

Implementation Reference

  • The handler function for the 'extract-audio' tool. It proxies the request to an external API endpoint at `${NWS_API_BASE}/api/v1/extract-audio`, passing the input parameters and returning the JSON response as text content.
    async ({ inputMethod, audio, prompt, jsonMode }) => {
      const apiKey = process.env.DUMPLING_API_KEY;
      if (!apiKey) throw new Error("DUMPLING_API_KEY not set");
      const response = await fetch(`${NWS_API_BASE}/api/v1/extract-audio`, {
        method: "POST",
        headers: {
          "Content-Type": "application/json",
          Authorization: `Bearer ${apiKey}`,
        },
        body: JSON.stringify({
          inputMethod,
          audio,
          prompt,
          jsonMode,
          requestSource: "mcp",
        }),
      });
      if (!response.ok)
        throw new Error(`Failed: ${response.status} ${await response.text()}`);
      const data = await response.json();
      return { content: [{ type: "text", text: JSON.stringify(data, null, 2) }] };
    }
  • Zod input schema defining the parameters for the 'extract-audio' tool: inputMethod (url or base64), audio (URL or base64), prompt, and optional jsonMode.
    {
      inputMethod: z.enum(["url", "base64"]).describe("Input method"),
      audio: z.string().describe("URL or base64-encoded audio"),
      prompt: z.string().describe("Extraction prompt"),
      jsonMode: z.boolean().optional().describe("Return in JSON format"),
    },
  • src/index.ts:726-757 (registration)
    Full registration of the 'extract-audio' tool via server.tool(), including name, description, input schema, and handler function.
    server.tool(
      "extract-audio",
      "Extract structured data from audio files based on a prompt.",
      {
        inputMethod: z.enum(["url", "base64"]).describe("Input method"),
        audio: z.string().describe("URL or base64-encoded audio"),
        prompt: z.string().describe("Extraction prompt"),
        jsonMode: z.boolean().optional().describe("Return in JSON format"),
      },
      async ({ inputMethod, audio, prompt, jsonMode }) => {
        const apiKey = process.env.DUMPLING_API_KEY;
        if (!apiKey) throw new Error("DUMPLING_API_KEY not set");
        const response = await fetch(`${NWS_API_BASE}/api/v1/extract-audio`, {
          method: "POST",
          headers: {
            "Content-Type": "application/json",
            Authorization: `Bearer ${apiKey}`,
          },
          body: JSON.stringify({
            inputMethod,
            audio,
            prompt,
            jsonMode,
            requestSource: "mcp",
          }),
        });
        if (!response.ok)
          throw new Error(`Failed: ${response.status} ${await response.text()}`);
        const data = await response.json();
        return { content: [{ type: "text", text: JSON.stringify(data, null, 2) }] };
      }
    );
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. It states the tool extracts structured data based on a prompt, but doesn't describe what 'structured data' entails (e.g., JSON, text), potential limitations (e.g., audio quality requirements, processing time), or error handling. For a tool with no annotation coverage, this leaves significant gaps in understanding its behavior.

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, efficient sentence: 'Extract structured data from audio files based on a prompt.' It's front-loaded with the core action and resource, with no wasted words. Every part of the sentence contributes to understanding the tool's purpose, making it appropriately sized and well-structured.

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 the tool's complexity (audio processing with a prompt-driven extraction) and lack of annotations and output schema, the description is incomplete. It doesn't explain what 'structured data' means in the output, potential use cases, or limitations like supported audio formats or file sizes. For a tool with no structured data on behavior or output, more context is needed to guide effective use.

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?

The description adds minimal meaning beyond the input schema, which has 100% coverage with clear descriptions for all parameters. It implies that 'audio' refers to files and 'prompt' guides extraction, but doesn't elaborate on prompt examples or audio format specifics. With high schema coverage, the baseline is 3, as the schema does most of the work without needing extra detail in the description.

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 tool's purpose: 'Extract structured data from audio files based on a prompt.' It specifies the verb ('extract'), resource ('structured data'), and source ('audio files'), making it easy to understand. However, it doesn't explicitly differentiate from sibling tools like 'extract-video' or 'extract-document', which have similar extraction purposes but different input types.

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

Usage Guidelines2/5

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

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention sibling tools like 'extract-video' for video files or 'extract-document' for text extraction, nor does it specify prerequisites such as audio format compatibility or file size limits. Usage is implied by the tool name and description but not explicitly stated.

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/DumplingAI/mcp-server-dumplingai'

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