MCP server for the SpeakGlobal Developer API (/v1).
Project description
speak-global-mcp
Model Context Protocol server for the SpeakGlobal Developer API (/v1). Tools call the same JSON endpoints as API keys in the dashboard (Account → Developer).
Export endpoints are not implemented: GET /v1/tts/export-status, POST /v1/tts/export, POST /v1/recordings/export.
Requirements
- Python 3.10+
httpx,mcp,pydantic-settings(seepyproject.toml)
Install
cd speak-global-mcp
python -m venv .venv
.venv\Scripts\activate
pip install -e .
End users (Cursor, Claude Desktop, any stdio MCP client)
Cursor runs MCP over stdio: it starts a local process on your machine. There is no need to host a public MCP URL for normal use—each person installs the package once and puts their own Developer API key in config.
1. Install (pick one)
-
pipx (isolates dependencies; recommended if you have Python 3.10+):
pipx install git+https://github.com/Design-Aura/speak-global-MCP.git
Ensure pipx’s binary directory is on your
PATH(seepipx ensurepath). -
venv + pip from a clone or Git URL:
python -m venv .venv .venv\Scripts\activate # Windows # source .venv/bin/activate # macOS / Linux pip install git+https://github.com/Design-Aura/speak-global-MCP.git
2. Cursor mcp.json
User-level file (example paths): Windows %USERPROFILE%\.cursor\mcp.json, macOS/Linux ~/.cursor/mcp.json. Use the speakglobal-mcp executable if it is on PATH (after pipx); otherwise set command to your venv’s python and args to ["-m", "speak_global_mcp.server"].
{
"mcpServers": {
"speakglobal": {
"command": "speakglobal-mcp",
"env": {
"SPEAKGLOBAL_ENVIRONMENT": "production",
"SPEAKGLOBAL_API_BASE": "https://api.speakglobal.ai",
"SPEAKGLOBAL_API_KEY": "sg_live_REPLACE_ME"
}
}
}
}
Use production when calling the real API: it enforces https:// on SPEAKGLOBAL_API_BASE and requires a non-empty key. Restart Cursor after editing.
3. Optional: PyPI install
After the package is published to PyPI, end users can run pipx install speak-global-mcp (or pip install speak-global-mcp) instead of the Git URL.
Hosted MCP over HTTP (teams / automation)
The Docker image can expose SSE or streamable-http on a port (see Docker). Use that when a client connects over the network (automation, or products that support remote MCP). Do not expose it on the public internet without TLS and an access policy: the process still holds one SPEAKGLOBAL_API_KEY. Confirm whether your Cursor build supports remote MCP URLs; many setups use local stdio only.
Development (tests):
pip install -e ".[dev]"
pytest
Package layout
| Module | Role |
|---|---|
speak_global_mcp.server |
Entrypoint: loads tools + observability, exports mcp and main. |
speak_global_mcp.mcp_instance |
FastMCP singleton. |
speak_global_mcp.tools |
@mcp.tool() handlers. |
speak_global_mcp.observability |
GET /health, GET /ready (HTTP transports only). |
speak_global_mcp.http_client |
Backend requests, errors, path encoding. |
speak_global_mcp.config |
SPEAKGLOBAL_* settings. |
speak_global_mcp.runtime |
Logging and main(). |
Configuration
SPEAKGLOBAL_*
| Variable | Default | Notes |
|---|---|---|
ENVIRONMENT |
development |
production enforces https on API_BASE and non-empty API_KEY. |
API_BASE |
http://127.0.0.1:8000 |
Origin only; trailing / stripped. |
API_KEY |
(empty) | Bearer token (sg_live_…). |
MCP_TRANSPORT |
stdio |
stdio | sse | streamable-http. |
LOG_LEVEL |
INFO |
DEBUG | INFO | WARNING | ERROR. |
HTTP_TIMEOUT_TOTAL |
300 |
Seconds. |
HTTP_TIMEOUT_CONNECT |
30 |
Seconds. |
HTTP_VERIFY_SSL |
true |
Set false only for local TLS testing. |
HTTP_TRUST_ENV |
false |
If true, httpx uses proxy env vars. |
HTTP_MAX_CONNECTIONS |
100 |
Pool size. |
HTTP_MAX_KEEPALIVE_CONNECTIONS |
20 |
Keepalive cap. |
READY_DEEP_PROBE |
false |
If true, GET /ready issues GET /v1/me. |
Prefix: all of the above are read as SPEAKGLOBAL_<NAME> (e.g. SPEAKGLOBAL_API_BASE).
FASTMCP_* (HTTP transports)
Used by FastMCP/uvicorn when MCP_TRANSPORT is sse or streamable-http:
| Variable | Default |
|---|---|
FASTMCP_HOST |
127.0.0.1 |
FASTMCP_PORT |
8000 |
FASTMCP_LOG_LEVEL |
INFO |
Run
Stdio (e.g. Cursor / Claude Desktop):
speakglobal-mcp
Or:
python -m speak_global_mcp.server
Example mcp.json env block:
{
"SPEAKGLOBAL_API_BASE": "https://api.example.com",
"SPEAKGLOBAL_API_KEY": "sg_live_…"
}
HTTP: set SPEAKGLOBAL_MCP_TRANSPORT, bind with FASTMCP_HOST / FASTMCP_PORT, terminate TLS at the load balancer or reverse proxy.
Tools
| Tool | HTTP |
|---|---|
account_summary |
GET /v1/me |
list_voice_profiles |
GET /v1/voice-profiles |
get_voice_profile |
GET /v1/voice-profiles/{session_id} |
list_recordings |
GET /v1/recordings |
get_recording |
GET /v1/recordings/{session_id} |
generate_tts |
POST /v1/tts/generate |
presign_audio_upload |
GET /v1/recordings/presign |
register_recording_from_url |
POST /v1/recordings/upload/with-url |
start_transcription |
POST /v1/processing/transcribe |
start_enhance |
POST /v1/processing/enhance |
edit_transcript |
POST /v1/processing/edit-transcript |
start_re_enhance |
POST /v1/processing/re-enhance |
get_job_status |
GET /v1/jobs/{job_id} |
list_jobs_for_session |
GET /v1/jobs/session/{session_id} |
Scopes are enforced on the API; use a key with the minimum scopes required.
HTTP observability
On sse / streamable-http:
GET /health— process up, no upstream call.GET /ready— configuration and API key present; optional deep probe viaREADY_DEEP_PROBE.
Docker
docker build -t speak-global-mcp .
docker run --rm -p 8080:8080 \
-e SPEAKGLOBAL_API_BASE=https://api.example.com \
-e SPEAKGLOBAL_API_KEY=sg_live_… \
speak-global-mcp
Image defaults: non-root user, streamable-http, FASTMCP_HOST=0.0.0.0, FASTMCP_PORT=8080. Adjust env as needed.
CI/CD (GitHub Actions)
| Workflow | Trigger | Purpose |
|---|---|---|
| ci.yml | Push / PR to main |
pytest on Python 3.10–3.13 |
| publish-pypi.yml | Release published | Build wheel + sdist, upload to PyPI via trusted publishing (OIDC; no PYPI_API_TOKEN secret) |
Release checklist: PyPI rejects duplicate versions — each release needs a new semver in pyproject.toml.
Automated (recommended): from repo root, on branch main, with a clean working tree and GitHub CLI on your PATH, logged in via gh auth login. On Windows: winget install --id GitHub.cli, then restart the terminal.
python scripts/bump_and_release.py patch # or minor | major
python scripts/bump_and_release.py --set 1.2.0 -y # exact version; -y skips confirm
python scripts/bump_and_release.py minor --dry-run # print steps only
This updates pyproject.toml, commits chore: release vX.Y.Z, pushes main, and runs gh release create (published release → triggers PyPI workflow).
Manual: edit version in pyproject.toml, push main, then create a GitHub Release from a new tag.
One-time PyPI: Add a pending publisher — GitHub → owner/repo that hosts this code → workflow file name publish-pypi.yml. The first project upload may require a manual twine upload once if PyPI has not seen speak-global-mcp yet; after that, trusted publishing can own releases.
Publishing to PyPI (maintainers)
PyPI is the index behind pip install speak-global-mcp. You upload wheels + sdist built from this repo; each version can only be uploaded once (bump version in pyproject.toml for every release).
One-time setup
-
Create accounts on pypi.org and (recommended) test.pypi.org.
-
Create an API token under Account settings → API tokens (scope: entire account or single project after the first upload).
-
Configure credentials locally. With a token, username is always
__token__and the password is the token value (pypi-...). Example~/.pypirc(Unix) or%USERPROFILE%\.pypirc(Windows):[distutils] index-servers = pypi testpypi [pypi] username = __token__ password = pypi-YOUR_PRODUCTION_TOKEN [testpypi] repository = https://test.pypi.org/legacy/ username = __token__ password = pypi-YOUR_TEST_TOKEN
Alternatively pass the token once:
twine upload -u __token__ -p pypi-... dist/*
Do not commit tokens or.pypircinto Git. -
Optional: Trusted publishing (OpenID Connect from GitHub Actions) avoids long-lived tokens on your laptop.
Release workflow
From the speak-global-mcp directory (with a clean Git tree):
pip install build twine
# Remove old artifacts: dist/, build/, and any *.egg-info under src/
python -m build
twine check dist/*
Dry run on TestPyPI (same version string must not already exist on TestPyPI either):
twine upload --repository testpypi dist/*
Install from TestPyPI to verify:
pip install --index-url https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple/ speak-global-mcp
Production upload:
twine upload dist/*
After a successful upload, end users can run:
pipx install speak-global-mcp
# or: pip install speak-global-mcp
Tag the Git release (e.g. v0.1.0) to match pyproject.toml if you track versions in Git.
Security notes
- One
API_KEYper process maps to one developer account; scope keys narrowly. - Do not commit keys; inject via secret manager or env in orchestration.
- For public network exposure, use TLS in front of the MCP HTTP listener and restrict source IPs or add an authentication layer appropriate to your deployment.
register_recording_from_urlforwards URLs to your API; SSRF policy is defined server-side.
Tests
tests/ covers HTTP helpers, tool request shapes, response contracts, multi-step flows, config validation, and health routes. Run pytest from the package root.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file speak_global_mcp-0.1.1.tar.gz.
File metadata
- Download URL: speak_global_mcp-0.1.1.tar.gz
- Upload date:
- Size: 20.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e7dd770ede97a35da6ff5bba9d1df7bdc5c51a08e7ea106cfe816e18dd49ab84
|
|
| MD5 |
ef27eab8a5b1a5eb496f155afb9d09e2
|
|
| BLAKE2b-256 |
9bb90fda07b38d3a3dc70734f43d8bc08ba7aac01fc282d860c3a32f31e7fa21
|
Provenance
The following attestation bundles were made for speak_global_mcp-0.1.1.tar.gz:
Publisher:
publish-pypi.yml on Design-Aura/speak-global-MCP
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
speak_global_mcp-0.1.1.tar.gz -
Subject digest:
e7dd770ede97a35da6ff5bba9d1df7bdc5c51a08e7ea106cfe816e18dd49ab84 - Sigstore transparency entry: 1364095858
- Sigstore integration time:
-
Permalink:
Design-Aura/speak-global-MCP@8c39d2ab61571d3f407c2e96dce9bc4c536dd6d1 -
Branch / Tag:
refs/tags/v0.1.1 - Owner: https://github.com/Design-Aura
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-pypi.yml@8c39d2ab61571d3f407c2e96dce9bc4c536dd6d1 -
Trigger Event:
release
-
Statement type:
File details
Details for the file speak_global_mcp-0.1.1-py3-none-any.whl.
File metadata
- Download URL: speak_global_mcp-0.1.1-py3-none-any.whl
- Upload date:
- Size: 13.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8505567f7cd7c345f84b6007785f8d1bdfe8cc9dc17ff4b57748f52c8f56d030
|
|
| MD5 |
37ab7799bfc28fe7d4eafec522e1709d
|
|
| BLAKE2b-256 |
4c1c171149c9eca9862ea6837c3acf807c736782e891e22cc36f8473a0c450bc
|
Provenance
The following attestation bundles were made for speak_global_mcp-0.1.1-py3-none-any.whl:
Publisher:
publish-pypi.yml on Design-Aura/speak-global-MCP
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
speak_global_mcp-0.1.1-py3-none-any.whl -
Subject digest:
8505567f7cd7c345f84b6007785f8d1bdfe8cc9dc17ff4b57748f52c8f56d030 - Sigstore transparency entry: 1364095998
- Sigstore integration time:
-
Permalink:
Design-Aura/speak-global-MCP@8c39d2ab61571d3f407c2e96dce9bc4c536dd6d1 -
Branch / Tag:
refs/tags/v0.1.1 - Owner: https://github.com/Design-Aura
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-pypi.yml@8c39d2ab61571d3f407c2e96dce9bc4c536dd6d1 -
Trigger Event:
release
-
Statement type: