CleanJobData MCP Server
A Model Context Protocol (MCP) server providing tools to interact with the CleanJobData Job API.
It runs two ways:
- stdio (default) — your MCP client launches it locally and it uses the
CLEANJOBDATA_API_KEYenv var. - HTTP (
--transport http) — one hosted server, many users, each authenticating with their own CleanJobData key sent per request. See Running as a remote HTTP server.
Available MCP Interactions
This server exposes the following MCP interactions:
Tools
search_jobs: Search for jobs using the CleanJobData API based on various criteria.- Parameters:
title,sort_by,city_id,state_id,country_id,location,remote,remote_type,company_name,employer_id,salary_min,salary_max,require_salary,experience_level,employment_type,published_after,max_age,include_expired,include_description,limit,cursor,count.
- Parameters:
get_job: Retrieve detailed information about a specific job (including its full description) by ID.- Parameters:
job_id.
- Parameters:
search_companies: Search for companies by name (fuzzy), website domain, or company IDs.- Parameters:
query,website_url,employer_id,active,limit,offset.
- Parameters:
get_company: Retrieve detailed information about a specific company, including enrichment data.- Parameters:
company_id.
- Parameters:
suggest_locations: Autocomplete city/state/country names into the IDs used bysearch_jobsgeo filters.- Parameters:
query,kinds,limit.
- Parameters:
Prompts
create_candidate_profile: Generates a structured prompt based on candidate details (name, LinkedIn, website, resume text) to help guide job searching.- Parameters:
name,linkedin_url,personal_website,resume_text.
- Parameters:
Client Setup (Examples: Claude Desktop, Cursor)
To use this server with an MCP client like Claude Desktop or Cursor, you need to configure the client to run the server process and provide the CleanJobData API key.
-
Ensure
uvis installed:curl -LsSf https://astral.sh/uv/install.sh | sh -
Obtain a CleanJobData API Key: Request a key from CleanJobData. Set it as the
CLEANJOBDATA_API_KEYenvironment variable. -
Configure your client:
-
Using
uvx:- Claude Desktop: Edit your
claude_desktop_config.json:{ "mcpServers": { "cleanjobdata": { "command": "uvx", "args": [ "cleanjobdata-mcp" ], "env": { "CLEANJOBDATA_API_KEY": "" } } } }
- Cursor: Go to Settings > MCP > Add Server:
- Mac/Linux Command:
uvx cleanjobdata-mcp - Windows Command:
cmd - Windows Args:
/c,uvx,cleanjobdata-mcp - Set the
CLEANJOBDATA_API_KEYenvironment variable in the appropriate section.
- Mac/Linux Command:
- Claude Desktop: Edit your
-
Running from source (Alternative):
- Clone the repo and note where you clone it to
- Claude Desktop: Edit your
claude_desktop_config.json:
{ "mcpServers": { "cleanjobdata": { "command": "uv", "args": [ "run", "--directory", "PATH_TO_REPO", "cleanjobdata-mcp" ], "env": { "CLEANJOBDATA_API_KEY": "" } } } }
-
Running as a remote HTTP server
The HTTP transport serves many users from a single process. Each request carries its own CleanJobData API key, so the server holds no user credentials and every upstream call is billed to the caller who made it.
cleanjobdata-mcp --transport http --host 0.0.0.0 --port 8000
The MCP endpoint is POST /mcp (streamable HTTP); GET /healthz is an unauthenticated liveness probe.
How clients authenticate
A client sends its key on every request, in either header:
Authorization: Bearer <cleanjobdata-api-key>
X-CleanJobData-API-Key: <cleanjobdata-api-key>
X-CleanJobData-API-Key wins if both are present. A request with neither is rejected with a message
telling the caller how to supply one — it does not silently fall back to the server's own key.
Example client config (Claude Desktop / Cursor remote MCP server):
{
"mcpServers": {
"cleanjobdata": {
"url": "https://your-host.example.com/mcp",
"headers": {
"Authorization": "Bearer YOUR_CLEANJOBDATA_API_KEY"
}
}
}
}
Or from the command line:
npx mcp-remote https://your-host.example.com/mcp --header "Authorization: Bearer YOUR_KEY"
Docker
docker build -t cleanjobdata-mcp .
docker run --rm -p 8000:8000 cleanjobdata-mcp
The image ships no API key — keys arrive per request. It defaults to MCP_TRANSPORT=http,
HOST=0.0.0.0, PORT=8000, and runs as a non-root user.
Scaling out
Requests are stateless by default, so you can run several replicas behind a load balancer with no sticky sessions. To use your own ASGI server with multiple workers:
uvicorn cleanjobdata_mcp.app:app --host 0.0.0.0 --port 8000 --workers 4
Pass --stateful (or MCP_STATEFUL=1) only if you need per-session server state; that requires
sticky routing.
Single-tenant HTTP deployments
If you want one hosted server that always uses your key rather than the caller's, set both
CLEANJOBDATA_API_KEY and CLEANJOBDATA_ALLOW_ENV_KEY_FALLBACK=true. Requests that supply their own
key still use it; requests without one fall back to the server's key. Leave this off for anything
multi-user — otherwise a user who forgets their header gets billed to you.
CLI options
| Flag | Env var | Default | Purpose |
|---|---|---|---|
--transport |
MCP_TRANSPORT |
stdio |
stdio or http |
--host |
HOST |
127.0.0.1 |
Bind address (use 0.0.0.0 in a container) |
--port |
PORT |
8000 |
Bind port |
--path |
MCP_PATH |
/mcp |
URL path of the MCP endpoint |
--json-response |
MCP_JSON_RESPONSE |
off | Plain JSON instead of SSE, for proxies that buffer |
--stateful |
MCP_STATEFUL |
off | Keep per-session state in memory |
--allowed-host |
MCP_ALLOWED_HOSTS |
none | Allowed Host values; setting any enables DNS-rebinding protection |
--allowed-origin |
MCP_ALLOWED_ORIGINS |
none | Allowed Origin values |
Operational notes
- Terminate TLS in front of the server (load balancer, reverse proxy, or platform ingress). Keys travel in request headers, so plain HTTP over the public internet would expose them.
- Tool handlers run in a thread pool, so a slow upstream call blocks one thread rather than the whole event loop. Very high concurrency benefits from more replicas rather than one large process.
Development
This project uses:
uvfor dependency management and virtual environmentsrufffor linting and formattinghatchas the build backend
Common Tasks
# Setup virtual env
uv venv
# Install dependencies
uv pip install -e .
# install cli tools
uv tool install ruff
# Run linting
ruff check .
# Format code
ruff format .
Environment Variables
CLEANJOBDATA_API_KEY: Your API key for the CleanJobData API, sent upstream as a Bearer token. Required for stdio; over HTTP the caller's own header supplies the key instead.CLEANJOBDATA_ALLOW_ENV_KEY_FALLBACK: Set totrueto let HTTP requests without a key fall back toCLEANJOBDATA_API_KEY. Off by default — see Single-tenant HTTP deployments.CLEANJOBDATA_API_BASE: Override the API base URL (defaulthttps://api.cleanjobdata.com).
Transport settings (MCP_TRANSPORT, HOST, PORT, …) are listed under CLI options.
Testing
This project uses pytest for testing the core tool logic. Tests mock external API calls using unittest.mock.
- Install test dependencies:
# Ensure you are in your activated virtual environment (.venv)
uv pip install -e '.[test]'
- Run tests:
pytest
Contributing
Contributions are welcome.
License
This project is licensed under the MIT License - see the LICENSE file for details.
Metadata
Release files for cleanjobdata-mcp 0.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| cleanjobdata_mcp-0.2.0.tar.gz | 94.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| cleanjobdata_mcp-0.2.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 108.0 kB
Release files / cleanjobdata_mcp-0.2.0.tar.gz
| Download URL | cleanjobdata_mcp-0.2.0.tar.gz |
|---|---|
| Size | 94.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
020b845fc228f0e1688475e472ec4f257f5f40fe0a6d6802f2dd285294e35946
|
|
BLAKE2b-256 checksum How to use checksums |
948313b81065c2c06487f61b9f03d42bac4733b8c8f57fba14e68ab1f364b1f0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Aug 5, 2026.
Transparency logRelease files / cleanjobdata_mcp-0.2.0-py3-none-any.whl
| Download URL | cleanjobdata_mcp-0.2.0-py3-none-any.whl |
|---|---|
| Size | 13.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f762def314917d2cb822dcb09aceff5c7470f85ffc3c3c1f98c0a8df97041aaf
|
|
BLAKE2b-256 checksum How to use checksums |
1b7b6fb7f23666699ccb4efc25f6e13ce76b3a44e355f22dd7bfd1126ea3426c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Aug 5, 2026.
Transparency log