Skip to main content
Glama
vocea-admin

@vocea.app/mcp-server

Official
by vocea-admin

vocea_generate_audio

Generate speech from text with a specified voice, language, and emotional tone. Returns an audio URL for immediate use.

Instructions

Convert text to speech using a Vocea voice. Returns an audio URL.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
voice_idYesVoice UUID to use for synthesis
textYesText to convert to speech (max 10000 chars)
language_codeYesLanguage code, e.g. 'en', 'es', 'fr'
emotionNoEmotional tone (default: neutral)
speaking_rateNoSpeaking rate multiplier 0.5–1.5 (default 1.0)

Implementation Reference

  • Handler for the vocea_generate_audio tool. It extracts the required arguments (voice_id, text, language_code) and optional arguments (emotion, speaking_rate), calls the Vocea SDK's audios.generate() method, and returns a JSON response with id, audioUrl, durationSeconds, and characterCount.
    case "vocea_generate_audio": {
      const a = args as { voice_id: string; text: string; language_code: string; emotion?: string; speaking_rate?: number };
      const audio = await vocea.audios.generate({
        voice_id: a.voice_id,
        text: a.text,
        language_code: a.language_code,
        voice_setting: {
          emotion: (a.emotion as never) ?? "neutral",
          speakingRate: a.speaking_rate ?? 1.0,
        },
      });
      return {
        content: [
          {
            type: "text",
            text: JSON.stringify({
              id: audio.id,
              audioUrl: audio.audioUrl,
              durationSeconds: audio.durationSeconds,
              characterCount: audio.characterCount,
            }),
          },
        ],
      };
    }
  • Schema/registration definition for vocea_generate_audio in the ListToolsResponse. Defines the inputSchema with required properties: voice_id (string), text (string, max 10000 chars), language_code (string), and optional properties: emotion (enum of emotional tones), speaking_rate (number 0.5-1.5).
    {
      name: "vocea_generate_audio",
      description: "Convert text to speech using a Vocea voice. Returns an audio URL.",
      inputSchema: {
        type: "object",
        properties: {
          voice_id: { type: "string", description: "Voice UUID to use for synthesis" },
          text: { type: "string", description: "Text to convert to speech (max 10000 chars)" },
          language_code: { type: "string", description: "Language code, e.g. 'en', 'es', 'fr'" },
          emotion: {
            type: "string",
            enum: ["neutral", "happy", "sad", "angry", "fearful", "surprised", "disgusted", "whisper"],
            description: "Emotional tone (default: neutral)",
          },
          speaking_rate: { type: "number", description: "Speaking rate multiplier 0.5–1.5 (default 1.0)" },
        },
        required: ["voice_id", "text", "language_code"],
      },
  • src/index.ts:28-100 (registration)
    The tool is registered with the MCP server via ListToolsRequestSchema, listing all six tools including vocea_generate_audio as part of the tools array.
    server.setRequestHandler(ListToolsRequestSchema, async () => ({
      tools: [
        {
          name: "vocea_generate_audio",
          description: "Convert text to speech using a Vocea voice. Returns an audio URL.",
          inputSchema: {
            type: "object",
            properties: {
              voice_id: { type: "string", description: "Voice UUID to use for synthesis" },
              text: { type: "string", description: "Text to convert to speech (max 10000 chars)" },
              language_code: { type: "string", description: "Language code, e.g. 'en', 'es', 'fr'" },
              emotion: {
                type: "string",
                enum: ["neutral", "happy", "sad", "angry", "fearful", "surprised", "disgusted", "whisper"],
                description: "Emotional tone (default: neutral)",
              },
              speaking_rate: { type: "number", description: "Speaking rate multiplier 0.5–1.5 (default 1.0)" },
            },
            required: ["voice_id", "text", "language_code"],
          },
        },
        {
          name: "vocea_list_voices",
          description: "List the authenticated user's cloned voices.",
          inputSchema: {
            type: "object",
            properties: {
              page: { type: "number", description: "Page number (default 1)" },
              limit: { type: "number", description: "Results per page (default 20)" },
            },
          },
        },
        {
          name: "vocea_list_public_voices",
          description: "List public community voices available for use.",
          inputSchema: {
            type: "object",
            properties: {
              page: { type: "number" },
              limit: { type: "number" },
              ageRange: { type: "string", enum: ["young", "adult", "senior"] },
            },
          },
        },
        {
          name: "vocea_transcribe",
          description: "Transcribe audio from a base64-encoded string to text (STT).",
          inputSchema: {
            type: "object",
            properties: {
              audio_base64: { type: "string", description: "Base64-encoded audio file (mp3, wav, ogg, webm, flac, max 10MB)" },
              mime_type: { type: "string", description: "MIME type, e.g. audio/mpeg", default: "audio/mpeg" },
              language: { type: "string", description: "BCP-47 language code, e.g. en-US (default: es-ES)" },
            },
            required: ["audio_base64"],
          },
        },
        {
          name: "vocea_get_credits",
          description: "Get the current credit balance for the authenticated user.",
          inputSchema: { type: "object", properties: {} },
        },
        {
          name: "vocea_get_audio",
          description: "Get details (including CDN URL) for a previously generated audio.",
          inputSchema: {
            type: "object",
            properties: { audio_id: { type: "string" } },
            required: ["audio_id"],
          },
        },
      ],
    }));
Behavior2/5

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

Without annotations, the description must disclose behavioral traits. It only states the output is an audio URL but does not mention if the URL is temporary, any rate limits, synchronous/asynchronous behavior, or error conditions. Minimal transparency.

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

Conciseness3/5

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

The description is very short and front-loaded, but it is too brief. While concise, it does not provide enough detail to fully inform an AI agent. It lacks elaboration that would justify its brevity.

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 5 parameters, no output schema, and no annotations, the description is insufficient. It does not explain how to use optional parameters like emotion or speaking_rate, nor does it describe the return format beyond 'audio URL'. Incomplete for real-world 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?

Schema description coverage is 100%, so the schema already documents all parameters. The description adds no additional meaning beyond the schema. Baseline score of 3 is appropriate.

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 'Convert text to speech' and the resource 'using a Vocea voice', and specifies the output 'Returns an audio URL'. It effectively distinguishes from sibling tools like vocea_transcribe (speech to text).

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?

No usage guidelines are provided. The description does not specify when to use this tool versus alternatives such as vocea_get_audio or vocea_list_voices, nor does it mention any prerequisites or context.

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/vocea-admin/mcp-server'

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