listAudioVoices
Retrieve the complete list of available voices for text-to-speech generation. Use this to select the appropriate voice for your audio output.
Instructions
List all available audio voices for text-to-speech generation
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/services/audioService.js:100-119 (handler)Main handler for listAudioVoices. Returns a list of available audio voices (alloy, echo, fable, onyx, nova, shimmer, coral, verse, ballad, ash, sage, amuch, dan).
export async function listAudioVoices() { // Return the complete list of available voices const voices = [ "alloy", "echo", "fable", "onyx", "nova", "shimmer", "coral", "verse", "ballad", "ash", "sage", "amuch", "dan" ]; return { voices }; } - src/services/audioSchema.js:36-43 (schema)Schema definition for listAudioVoices tool. Name: 'listAudioVoices', description: 'List all available audio voices for text-to-speech generation', no input parameters.
export const listAudioVoicesSchema = { name: 'listAudioVoices', description: 'List all available audio voices for text-to-speech generation', inputSchema: { type: 'object', properties: {} } }; - pollinations-mcp-server.js:329-344 (registration)MCP server handler routing for the 'listAudioVoices' tool call. Invokes listAudioVoices() and returns the result as JSON text content.
} else if (name === 'listAudioVoices') { try { const result = await listAudioVoices(); return { content: [ { type: 'text', text: JSON.stringify(result, null, 2) } ] }; } catch (error) { return { content: [ { type: 'text', text: `Error listing audio voices: ${error.message}` } ], isError: true }; } - src/schemas.js:21-26 (registration)Central schema export: re-exports listAudioVoicesSchema and includes it in getAllToolSchemas() for MCP tool registration.
listAudioVoicesSchema, // Text schemas respondTextSchema, listTextModelsSchema }; - src/index.js:22-29 (helper)Re-exports listAudioVoices from audioService.js so it can be imported by the MCP server.
// Audio services respondAudio, listAudioVoices, // Text services respondText, listTextModels, };