@mindstone/mcp-server-elevenlabs 0.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE ADDED
@@ -0,0 +1,97 @@
1
+ # Functional Source License, Version 1.1, MIT Future License
2
+
3
+ ## Abbreviation
4
+
5
+ FSL-1.1-MIT
6
+
7
+ ## Notice
8
+
9
+ Copyright 2026 Mindstone Learning Limited
10
+
11
+ ## Terms and Conditions
12
+
13
+ ### Licensor ("We")
14
+
15
+ The party offering the Software under these Terms and Conditions.
16
+
17
+ **Licensor**: Mindstone Learning Limited
18
+
19
+ ### The Software
20
+
21
+ The "Software" is each version of the software that we make available under
22
+ these Terms and Conditions, as indicated by our inclusion of these Terms and
23
+ Conditions with the Software.
24
+
25
+ **Software**: ElevenLabs MCP Server
26
+
27
+ ### License Grant
28
+
29
+ Subject to your compliance with this License Grant and the Patents,
30
+ Redistribution and Trademark clauses below, we hereby grant you the right to
31
+ use, copy, modify, create derivative works, publicly perform, publicly display
32
+ and redistribute the Software for any Permitted Purpose identified below.
33
+
34
+ ### Permitted Purpose
35
+
36
+ A Permitted Purpose is any purpose other than a Competing Use. A "Competing
37
+ Use" means making the Software available to third parties as a commercial
38
+ hosted service that directly competes with any product or service provided by
39
+ the Licensor.
40
+
41
+ ### Patents
42
+
43
+ To the extent your use for a Permitted Purpose would necessarily infringe our
44
+ patents, the license grant above includes a license under our patents. If you
45
+ make a claim against any party that the Software infringes or contributes to
46
+ the infringement of any patent, then your patent license to the Software ends
47
+ immediately.
48
+
49
+ ### Redistribution
50
+
51
+ The Terms and Conditions apply to all copies, modifications and derivatives of
52
+ the Software.
53
+
54
+ If you redistribute any copies, modifications or derivatives of the Software,
55
+ you must include a copy of or a link to these Terms and Conditions and not
56
+ remove any copyright notices provided in or with the Software.
57
+
58
+ ### Disclaimer
59
+
60
+ THE SOFTWARE IS PROVIDED "AS IS" AND WITHOUT WARRANTIES OF ANY KIND, EXPRESS OR
61
+ IMPLIED, INCLUDING WITHOUT LIMITATION WARRANTIES OF FITNESS FOR A PARTICULAR
62
+ PURPOSE, MERCHANTABILITY, TITLE OR NON-INFRINGEMENT.
63
+
64
+ IN NO EVENT WILL WE HAVE ANY LIABILITY TO YOU ARISING OUT OF OR RELATED TO THE
65
+ SOFTWARE, INCLUDING INDIRECT, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES, OF
66
+ ANY CHARACTER INCLUDING DAMAGES FOR LOSS OF GOODWILL, LOST PROFITS, LOST SALES
67
+ OR BUSINESS, WORK STOPPAGE, COMPUTER FAILURE OR MALFUNCTION, LOST CONTENT,
68
+ DATA OR DATA USE, BREACH OF DUTY OF GOOD FAITH, OR ANY AND ALL OTHER DAMAGES
69
+ OR LOSSES OF ANY KIND OR NATURE WHATSOEVER (WHETHER DIRECT, INDIRECT, SPECIAL,
70
+ COLLATERAL, INCIDENTAL, CONSEQUENTIAL OR OTHERWISE) ARISING OUT OF OR IN
71
+ CONNECTION WITH THE SOFTWARE OR THIS LICENSE, EVEN IF SUCH PARTY SHALL HAVE
72
+ BEEN INFORMED OF THE POSSIBILITY OF SUCH DAMAGES.
73
+
74
+ ### Trademark
75
+
76
+ Except for displaying the License Details and identifying us as the origin of
77
+ the Software, you have no right under these Terms and Conditions to use our
78
+ trademarks, trade names, service marks or product names.
79
+
80
+ ## Change Date
81
+
82
+ Four years from the date the Software is made available under these Terms and
83
+ Conditions: **2030-04-08**
84
+
85
+ ## Change License
86
+
87
+ MIT License
88
+
89
+ ## License Details
90
+
91
+ | Parameter | Value |
92
+ |---|---|
93
+ | Licensor | Mindstone Learning Limited |
94
+ | Software | ElevenLabs MCP Server |
95
+ | Use Limitation | Competing Use |
96
+ | Change Date | 2030-04-08 |
97
+ | Change License | MIT |
package/README.md ADDED
@@ -0,0 +1,99 @@
1
+ # @mindstone/mcp-server-elevenlabs
2
+
3
+ [![npm version](https://img.shields.io/npm/v/@mindstone/mcp-server-elevenlabs.svg)](https://www.npmjs.com/package/@mindstone/mcp-server-elevenlabs)
4
+ [![License: FSL-1.1-MIT](https://img.shields.io/badge/License-FSL--1.1--MIT-blue.svg)](./LICENSE)
5
+
6
+ ElevenLabs MCP server for Model Context Protocol hosts. Generate speech, music, and sound effects, browse voices, and transcribe audio using the ElevenLabs API through a standardised MCP interface.
7
+
8
+ ## Requirements
9
+
10
+ - Node.js 20+
11
+ - npm
12
+
13
+ ## Quick Start
14
+
15
+ ### Install & build
16
+
17
+ ```bash
18
+ cd <path-to-repo>/connectors/elevenlabs
19
+ npm install
20
+ npm run build
21
+ ```
22
+
23
+ ### npx (once published)
24
+
25
+ ```bash
26
+ npx -y @mindstone/mcp-server-elevenlabs
27
+ ```
28
+
29
+ ### Local
30
+
31
+ ```bash
32
+ node dist/index.js
33
+ ```
34
+
35
+ ## Configuration
36
+
37
+ ### Environment variables
38
+
39
+ - `ELEVENLABS_API_KEY` — ElevenLabs API key (starts with `sk_`)
40
+ - `MCP_HOST_BRIDGE_STATE` — optional path to a host bridge state file used for credential management
41
+ - `MINDSTONE_REBEL_BRIDGE_STATE` — backwards-compatible alias for `MCP_HOST_BRIDGE_STATE`
42
+
43
+ ## Host configuration examples
44
+
45
+ ### Claude Desktop / Cursor
46
+
47
+ ```json
48
+ {
49
+ "mcpServers": {
50
+ "ElevenLabs": {
51
+ "command": "npx",
52
+ "args": ["-y", "@mindstone/mcp-server-elevenlabs"],
53
+ "env": {
54
+ "ELEVENLABS_API_KEY": "your-api-key"
55
+ }
56
+ }
57
+ }
58
+ }
59
+ ```
60
+
61
+ ### Local development (no npm publish needed)
62
+
63
+ ```json
64
+ {
65
+ "mcpServers": {
66
+ "ElevenLabs": {
67
+ "command": "node",
68
+ "args": ["<path-to-repo>/connectors/elevenlabs/dist/index.js"],
69
+ "env": {
70
+ "ELEVENLABS_API_KEY": "your-api-key"
71
+ }
72
+ }
73
+ }
74
+ }
75
+ ```
76
+
77
+ ## Tools (8)
78
+
79
+ ### Configuration
80
+ - `configure_elevenlabs_api_key` — Save your ElevenLabs API key
81
+
82
+ ### Voices
83
+ - `list_voices` — Search and browse available ElevenLabs voices
84
+
85
+ ### Speech
86
+ - `generate_speech` — Generate spoken audio from text using text-to-speech
87
+ - `generate_sound_effect` — Generate sound effects from a text description
88
+
89
+ ### Music
90
+ - `generate_music` — Generate music from a text prompt
91
+ - `create_music_plan` — Create a composition plan for music generation (free)
92
+ - `generate_music_from_plan` — Generate music from a composition plan
93
+
94
+ ### Transcription
95
+ - `transcribe_audio` — Transcribe speech from an audio file to text
96
+
97
+ ## Licence
98
+
99
+ [FSL-1.1-MIT](./LICENSE) — Functional Source License, Version 1.1, with MIT future licence. The software converts to MIT licence on 2030-04-08.
package/dist/auth.d.ts ADDED
@@ -0,0 +1,21 @@
1
+ /**
2
+ * ElevenLabs authentication module.
3
+ *
4
+ * Simple API key management — stored via env var (ELEVENLABS_API_KEY)
5
+ * or configured at runtime via the configure_elevenlabs_api_key tool.
6
+ *
7
+ * Auth: xi-api-key header on all API requests (NOT Bearer).
8
+ */
9
+ /**
10
+ * Get the current API key.
11
+ */
12
+ export declare function getApiKey(): string;
13
+ /**
14
+ * Set the API key at runtime (from configure tool).
15
+ */
16
+ export declare function setApiKey(key: string): void;
17
+ /**
18
+ * Check if an API key is configured.
19
+ */
20
+ export declare function hasApiKey(): boolean;
21
+ //# sourceMappingURL=auth.d.ts.map
package/dist/auth.js ADDED
@@ -0,0 +1,29 @@
1
+ /**
2
+ * ElevenLabs authentication module.
3
+ *
4
+ * Simple API key management — stored via env var (ELEVENLABS_API_KEY)
5
+ * or configured at runtime via the configure_elevenlabs_api_key tool.
6
+ *
7
+ * Auth: xi-api-key header on all API requests (NOT Bearer).
8
+ */
9
+ /** Runtime API key — starts from env, can be updated via configure tool. */
10
+ let apiKey = process.env.ELEVENLABS_API_KEY ?? '';
11
+ /**
12
+ * Get the current API key.
13
+ */
14
+ export function getApiKey() {
15
+ return apiKey;
16
+ }
17
+ /**
18
+ * Set the API key at runtime (from configure tool).
19
+ */
20
+ export function setApiKey(key) {
21
+ apiKey = key;
22
+ }
23
+ /**
24
+ * Check if an API key is configured.
25
+ */
26
+ export function hasApiKey() {
27
+ return apiKey.trim().length > 0;
28
+ }
29
+ //# sourceMappingURL=auth.js.map
@@ -0,0 +1,16 @@
1
+ /**
2
+ * Path to bridge state file, supporting both current and legacy env vars.
3
+ */
4
+ export declare const BRIDGE_STATE_PATH: string;
5
+ /**
6
+ * Send a request to the host app bridge.
7
+ *
8
+ * The bridge is an HTTP server running inside the host app (e.g. the host application)
9
+ * that handles credential management and other cross-process operations.
10
+ */
11
+ export declare const bridgeRequest: (urlPath: string, body: Record<string, unknown>) => Promise<{
12
+ success: boolean;
13
+ warning?: string;
14
+ error?: string;
15
+ }>;
16
+ //# sourceMappingURL=bridge.d.ts.map
package/dist/bridge.js ADDED
@@ -0,0 +1,43 @@
1
+ import * as fs from 'fs';
2
+ import { REQUEST_TIMEOUT_MS } from './types.js';
3
+ /**
4
+ * Path to bridge state file, supporting both current and legacy env vars.
5
+ */
6
+ export const BRIDGE_STATE_PATH = process.env.MCP_HOST_BRIDGE_STATE || process.env.MINDSTONE_REBEL_BRIDGE_STATE || '';
7
+ const loadBridgeState = () => {
8
+ if (!BRIDGE_STATE_PATH)
9
+ return null;
10
+ try {
11
+ const raw = fs.readFileSync(BRIDGE_STATE_PATH, 'utf8');
12
+ return JSON.parse(raw);
13
+ }
14
+ catch {
15
+ return null;
16
+ }
17
+ };
18
+ /**
19
+ * Send a request to the host app bridge.
20
+ *
21
+ * The bridge is an HTTP server running inside the host app (e.g. the host application)
22
+ * that handles credential management and other cross-process operations.
23
+ */
24
+ export const bridgeRequest = async (urlPath, body) => {
25
+ const bridge = loadBridgeState();
26
+ if (!bridge) {
27
+ return { success: false, error: 'Bridge not available' };
28
+ }
29
+ const response = await fetch(`http://127.0.0.1:${bridge.port}${urlPath}`, {
30
+ method: 'POST',
31
+ signal: AbortSignal.timeout(REQUEST_TIMEOUT_MS),
32
+ headers: {
33
+ 'Content-Type': 'application/json',
34
+ Authorization: `Bearer ${bridge.token}`,
35
+ },
36
+ body: JSON.stringify(body),
37
+ });
38
+ if (response.status === 401 || response.status === 403) {
39
+ return { success: false, error: `Bridge returned ${response.status}: unauthorized. Check host app authentication.` };
40
+ }
41
+ return response.json();
42
+ };
43
+ //# sourceMappingURL=bridge.js.map
@@ -0,0 +1,25 @@
1
+ /**
2
+ * ElevenLabs API HTTP client.
3
+ *
4
+ * Centralises xi-api-key header injection, error handling, rate-limit
5
+ * messaging, and timeout handling for all ElevenLabs API calls.
6
+ *
7
+ * Auth: xi-api-key: {key} (NOT Bearer, NOT Basic)
8
+ * Base URL: https://api.elevenlabs.io/v1
9
+ * Voices URL: https://api.elevenlabs.io/v2/voices
10
+ */
11
+ import { type AudioResult } from './types.js';
12
+ /**
13
+ * Make an authenticated request to the ElevenLabs API.
14
+ * Returns a raw Response object.
15
+ */
16
+ export declare function elevenLabsFetch(apiKey: string, urlPath: string, options?: RequestInit): Promise<Response>;
17
+ /**
18
+ * Make a JSON API call and parse the response.
19
+ */
20
+ export declare function elevenLabsJson<T>(apiKey: string, urlPath: string, options?: RequestInit): Promise<T>;
21
+ /**
22
+ * Make an API call that returns raw audio binary. Save to file and return path.
23
+ */
24
+ export declare function elevenLabsAudio(apiKey: string, urlPath: string, options?: RequestInit, fileExtension?: string): Promise<AudioResult>;
25
+ //# sourceMappingURL=client.d.ts.map
package/dist/client.js ADDED
@@ -0,0 +1,108 @@
1
+ /**
2
+ * ElevenLabs API HTTP client.
3
+ *
4
+ * Centralises xi-api-key header injection, error handling, rate-limit
5
+ * messaging, and timeout handling for all ElevenLabs API calls.
6
+ *
7
+ * Auth: xi-api-key: {key} (NOT Bearer, NOT Basic)
8
+ * Base URL: https://api.elevenlabs.io/v1
9
+ * Voices URL: https://api.elevenlabs.io/v2/voices
10
+ */
11
+ import * as fs from 'fs';
12
+ import * as path from 'path';
13
+ import * as os from 'os';
14
+ import * as crypto from 'crypto';
15
+ import { ElevenLabsError, REQUEST_TIMEOUT_MS, getErrorResolution, } from './types.js';
16
+ const ELEVENLABS_API_BASE = 'https://api.elevenlabs.io/v1';
17
+ /**
18
+ * Make an authenticated request to the ElevenLabs API.
19
+ * Returns a raw Response object.
20
+ */
21
+ export async function elevenLabsFetch(apiKey, urlPath, options = {}) {
22
+ if (!apiKey || apiKey.trim().length === 0) {
23
+ throw new ElevenLabsError('ElevenLabs API key not configured', 'AUTH_REQUIRED', 'Configure your ElevenLabs API key in Settings. Get one at https://elevenlabs.io/app/settings/api-keys');
24
+ }
25
+ const url = urlPath.startsWith('https://')
26
+ ? urlPath
27
+ : `${ELEVENLABS_API_BASE}${urlPath}`;
28
+ const headers = {
29
+ 'xi-api-key': apiKey,
30
+ ...(options.headers || {}),
31
+ };
32
+ // Only set Content-Type for JSON bodies (not FormData)
33
+ if (!(options.body instanceof FormData) && !headers['Content-Type']) {
34
+ headers['Content-Type'] = 'application/json';
35
+ }
36
+ console.error(`[ElevenLabs API] ${options.method || 'GET'} ${url}`);
37
+ let response;
38
+ try {
39
+ response = await fetch(url, {
40
+ ...options,
41
+ signal: options.signal ?? AbortSignal.timeout(REQUEST_TIMEOUT_MS),
42
+ headers,
43
+ });
44
+ }
45
+ catch (error) {
46
+ if (error instanceof Error && error.name === 'TimeoutError') {
47
+ throw new ElevenLabsError('Request to ElevenLabs API timed out', 'TIMEOUT', 'The request took too long. Try again or check if the ElevenLabs API is available.');
48
+ }
49
+ throw error;
50
+ }
51
+ // Handle rate limiting
52
+ if (response.status === 429) {
53
+ throw new ElevenLabsError('Rate limited. Please wait a moment before retrying.', 'RATE_LIMITED', getErrorResolution(429));
54
+ }
55
+ // Handle auth errors
56
+ if (response.status === 401) {
57
+ throw new ElevenLabsError('Authentication failed', 'AUTH_FAILED', getErrorResolution(401));
58
+ }
59
+ if (response.status === 403) {
60
+ let detail = '';
61
+ try {
62
+ const errBody = await response.clone().json();
63
+ if (typeof errBody.detail === 'string') {
64
+ detail = errBody.detail;
65
+ }
66
+ else if (errBody.detail?.message) {
67
+ detail = errBody.detail.message;
68
+ }
69
+ }
70
+ catch { /* not JSON */ }
71
+ throw new ElevenLabsError(`Access forbidden: ${detail || 'insufficient permissions or quota'}`, 'AUTH_FAILED', getErrorResolution(403, detail));
72
+ }
73
+ // Handle other errors
74
+ if (!response.ok) {
75
+ let detail = '';
76
+ try {
77
+ const errBody = await response.clone().json();
78
+ if (typeof errBody.detail === 'string') {
79
+ detail = errBody.detail;
80
+ }
81
+ else if (errBody.detail?.message) {
82
+ detail = errBody.detail.message;
83
+ }
84
+ }
85
+ catch { /* not JSON */ }
86
+ throw new ElevenLabsError(`ElevenLabs API error (HTTP ${response.status}): ${detail || response.statusText}`, `HTTP_${response.status}`, getErrorResolution(response.status, detail));
87
+ }
88
+ return response;
89
+ }
90
+ /**
91
+ * Make a JSON API call and parse the response.
92
+ */
93
+ export async function elevenLabsJson(apiKey, urlPath, options = {}) {
94
+ const response = await elevenLabsFetch(apiKey, urlPath, options);
95
+ return (await response.json());
96
+ }
97
+ /**
98
+ * Make an API call that returns raw audio binary. Save to file and return path.
99
+ */
100
+ export async function elevenLabsAudio(apiKey, urlPath, options = {}, fileExtension = 'mp3') {
101
+ const response = await elevenLabsFetch(apiKey, urlPath, options);
102
+ const buffer = Buffer.from(await response.arrayBuffer());
103
+ const fileName = `elevenlabs_${crypto.randomUUID()}.${fileExtension}`;
104
+ const filePath = path.join(os.tmpdir(), fileName);
105
+ fs.writeFileSync(filePath, buffer);
106
+ return { filePath, sizeBytes: buffer.length };
107
+ }
108
+ //# sourceMappingURL=client.js.map
@@ -0,0 +1,14 @@
1
+ #!/usr/bin/env node
2
+ /**
3
+ * ElevenLabs MCP Server
4
+ *
5
+ * Provides ElevenLabs audio integration via Model Context Protocol.
6
+ * Music generation, text-to-speech, sound effects, voice browsing, transcription.
7
+ *
8
+ * Environment variables:
9
+ * - ELEVENLABS_API_KEY: ElevenLabs API key (required, starts with sk_)
10
+ * - MCP_HOST_BRIDGE_STATE: Path to host app bridge state file (primary, optional)
11
+ * - MINDSTONE_REBEL_BRIDGE_STATE: Legacy/deprecated bridge state path (optional)
12
+ */
13
+ export {};
14
+ //# sourceMappingURL=index.d.ts.map
package/dist/index.js ADDED
@@ -0,0 +1,25 @@
1
+ #!/usr/bin/env node
2
+ /**
3
+ * ElevenLabs MCP Server
4
+ *
5
+ * Provides ElevenLabs audio integration via Model Context Protocol.
6
+ * Music generation, text-to-speech, sound effects, voice browsing, transcription.
7
+ *
8
+ * Environment variables:
9
+ * - ELEVENLABS_API_KEY: ElevenLabs API key (required, starts with sk_)
10
+ * - MCP_HOST_BRIDGE_STATE: Path to host app bridge state file (primary, optional)
11
+ * - MINDSTONE_REBEL_BRIDGE_STATE: Legacy/deprecated bridge state path (optional)
12
+ */
13
+ import { StdioServerTransport } from '@modelcontextprotocol/sdk/server/stdio.js';
14
+ import { createServer } from './server.js';
15
+ async function main() {
16
+ const server = createServer();
17
+ const transport = new StdioServerTransport();
18
+ await server.connect(transport);
19
+ console.error('ElevenLabs MCP server running on stdio');
20
+ }
21
+ main().catch((error) => {
22
+ console.error('Fatal error:', error);
23
+ process.exit(1);
24
+ });
25
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1,3 @@
1
+ import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
2
+ export declare function createServer(): McpServer;
3
+ //# sourceMappingURL=server.d.ts.map
package/dist/server.js ADDED
@@ -0,0 +1,18 @@
1
+ import { createRequire } from 'node:module';
2
+ import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
3
+ import { registerConfigureTools, registerMusicTools, registerSpeechTools, registerVoiceTools, registerTranscriptionTools, } from './tools/index.js';
4
+ const require = createRequire(import.meta.url);
5
+ const pkg = require('../package.json');
6
+ export function createServer() {
7
+ const server = new McpServer({
8
+ name: 'elevenlabs-mcp-server',
9
+ version: pkg.version,
10
+ });
11
+ registerConfigureTools(server);
12
+ registerMusicTools(server);
13
+ registerSpeechTools(server);
14
+ registerVoiceTools(server);
15
+ registerTranscriptionTools(server);
16
+ return server;
17
+ }
18
+ //# sourceMappingURL=server.js.map
@@ -0,0 +1,3 @@
1
+ import type { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
2
+ export declare function registerConfigureTools(server: McpServer): void;
3
+ //# sourceMappingURL=configure.d.ts.map
@@ -0,0 +1,46 @@
1
+ import { z } from 'zod';
2
+ import { setApiKey } from '../auth.js';
3
+ import { bridgeRequest, BRIDGE_STATE_PATH } from '../bridge.js';
4
+ import { ElevenLabsError } from '../types.js';
5
+ import { withErrorHandling } from '../utils.js';
6
+ export function registerConfigureTools(server) {
7
+ server.registerTool('configure_elevenlabs_api_key', {
8
+ description: 'Save your ElevenLabs API key. Call this when the user provides their key. ' +
9
+ 'WHERE TO GET A KEY: Go to https://elevenlabs.io/app/settings/api-keys → Create new API key → Copy the key (starts with "sk_"). ' +
10
+ 'FREE TIER: 10,000 characters/month for TTS. Music generation requires a paid plan.',
11
+ inputSchema: z.object({
12
+ api_key: z.string().min(1).describe('ElevenLabs API key (starts with "sk_").'),
13
+ }),
14
+ annotations: { readOnlyHint: false, destructiveHint: true, openWorldHint: false },
15
+ }, withErrorHandling(async (args) => {
16
+ const key = args.api_key.trim();
17
+ // If bridge is available, persist via bridge
18
+ if (BRIDGE_STATE_PATH) {
19
+ try {
20
+ const result = await bridgeRequest('/bundled/elevenlabs/configure', { apiKey: key });
21
+ if (result.success) {
22
+ setApiKey(key);
23
+ const message = result.warning
24
+ ? `ElevenLabs API key configured successfully. Note: ${result.warning}`
25
+ : 'ElevenLabs API key configured successfully! You can now generate music, speech, sound effects, and more.';
26
+ return JSON.stringify({ ok: true, message });
27
+ }
28
+ // Bridge returned failure — surface as error, do NOT fall through
29
+ throw new ElevenLabsError(result.error || 'Bridge configuration failed', 'BRIDGE_ERROR', 'The host app bridge rejected the configuration request. Check the host app logs.');
30
+ }
31
+ catch (error) {
32
+ if (error instanceof ElevenLabsError)
33
+ throw error;
34
+ // Bridge request failed (network, timeout, etc.) — surface as error
35
+ throw new ElevenLabsError(`Bridge request failed: ${error instanceof Error ? error.message : String(error)}`, 'BRIDGE_ERROR', 'Could not reach the host app bridge. Ensure the host app is running.');
36
+ }
37
+ }
38
+ // No bridge — store in-memory
39
+ setApiKey(key);
40
+ return JSON.stringify({
41
+ ok: true,
42
+ message: 'ElevenLabs API key configured successfully! You can now generate music, speech, sound effects, and more.',
43
+ });
44
+ }));
45
+ }
46
+ //# sourceMappingURL=configure.js.map
@@ -0,0 +1,6 @@
1
+ export { registerConfigureTools } from './configure.js';
2
+ export { registerMusicTools } from './music.js';
3
+ export { registerSpeechTools } from './speech.js';
4
+ export { registerVoiceTools } from './voices.js';
5
+ export { registerTranscriptionTools } from './transcription.js';
6
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1,6 @@
1
+ export { registerConfigureTools } from './configure.js';
2
+ export { registerMusicTools } from './music.js';
3
+ export { registerSpeechTools } from './speech.js';
4
+ export { registerVoiceTools } from './voices.js';
5
+ export { registerTranscriptionTools } from './transcription.js';
6
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1,3 @@
1
+ import type { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
2
+ export declare function registerMusicTools(server: McpServer): void;
3
+ //# sourceMappingURL=music.d.ts.map