MCP server for Lightcast API integration using FastMCP
Project description
MCP Lightcast Server
A production-ready Model Context Protocol (MCP) server that provides seamless integration with Lightcast APIs for job titles, skills analysis, and career data. Built with FastMCP and modern Python development practices.
๐ฏ Current Status: v0.1.0 - Production Ready with 61% API Coverage (11/18 endpoints working)
๐ Features
โ Working APIs & Endpoints (11/18 total)
๐ฏ Skills API (6/10 endpoints) - Version 9.33, 41,139 skills
- โ Skills Search - Search with filters (type, category, subcategory)
- โ Individual Skill Retrieval - Get detailed skill information by ID
- โ Skills Extraction from Text - Extract skills from job descriptions with confidence scores
- โ Bulk Skills Retrieval - Efficient batch processing of multiple skills
- โ Version Metadata - Complete API version and statistics information
- โ Skills Metadata - General skills taxonomy information
๐ท๏ธ Titles API (5/8 endpoints) - Version 5.47, 73,993 titles
- โ Job Title Search - Search Lightcast's comprehensive job title database
- โ Individual Title Retrieval - Get detailed title information by ID
- โ Bulk Title Retrieval - Efficient batch processing of multiple titles
- โ Version Metadata - Complete API version and statistics information
- โ General Metadata - Latest version and attribution information
๐ง Core Functionality Working
- ๐ฏ Skills Extraction from Text - High accuracy skill identification from job descriptions
- ๐ Search & Discovery - Fast, filtered search across both skills and titles taxonomies
- โก Bulk Operations - Efficient processing of multiple items in single requests
- ๐ Version Management - Uses "latest" keyword with backward compatibility
- ๐ OAuth2 Authentication - Secure authentication with Lightcast APIs
โ ๏ธ Limited/Premium Features
- โ Title Normalization - Requires premium authentication scope
- โ Skills Categories - Endpoint not available in current API version
- โ Related Skills - Endpoint pattern differs from documentation
- โ Title Hierarchy - Endpoint pattern differs from documentation
๐ ๏ธ MCP Tools Available
Skills Tools
search_skills- Search skills with advanced filtersget_skill_details- Get detailed skill informationextract_skills_from_text- Extract skills with custom confidence thresholdextract_skills_simple- Extract skills with default settingsbulk_retrieve_skills- Efficient bulk skill retrievalget_skills_version_metadata- API version information
Titles Tools
search_job_titles- Search job titlesget_job_title_details- Get detailed title informationbulk_retrieve_titles- Efficient bulk title retrievalget_titles_version_metadata- API version informationget_titles_general_metadata- General taxonomy information
Combined Workflow Tools
normalize_title_and_get_skills- Complete workflow (where normalization is available)analyze_job_posting_skills- Comprehensive job posting analysis using skills extraction
๐ ๏ธ Installation
Prerequisites
- Python 3.12+ (required for uv-dynamic-versioning)
- uv package manager (recommended) or pip
- Lightcast API credentials (Client ID and Secret with
emsi_openscope)
๐ Quick Start with uvx (Recommended)
# Install and run directly from PyPI (no installation required)
uvx --from mcp-lightcast mcp-lightcast --help
# Run with environment variables
LIGHTCAST_CLIENT_ID=your_id LIGHTCAST_CLIENT_SECRET=your_secret \
uvx --from mcp-lightcast mcp-lightcast
# Use stdio transport for Claude Desktop
LIGHTCAST_CLIENT_ID=your_id LIGHTCAST_CLIENT_SECRET=your_secret \
uvx --from mcp-lightcast mcp-lightcast --transport stdio
๐ฆ Install from PyPI
# Install globally
pip install mcp-lightcast
# Or with uv
uv tool install mcp-lightcast
# Run the server
mcp-lightcast --help
๐ง Development Installation
# 1. Clone the repository
git clone https://github.com/your-org/mcp-lightcast.git
cd mcp-lightcast
# 2. Set up development environment
make setup
# 3. Configure your API credentials
# Edit .env with your Lightcast API credentials
# 4. Validate configuration
make validate-config
# 5. Run the server
make run
๐ณ Docker Installation
# Pull the latest image (when available)
docker pull ghcr.io/your-org/mcp-lightcast:latest
# Run with environment variables
docker run --rm -it \
-e LIGHTCAST_CLIENT_ID=your_id \
-e LIGHTCAST_CLIENT_SECRET=your_secret \
ghcr.io/your-org/mcp-lightcast:latest
# Or with environment file
docker run --rm -it --env-file .env ghcr.io/your-org/mcp-lightcast:latest
โ๏ธ Configuration
Environment Variables
Create a .env file with your Lightcast API credentials:
# Required - Lightcast API Configuration
LIGHTCAST_CLIENT_ID=your_client_id_here
LIGHTCAST_CLIENT_SECRET=your_client_secret_here
# Optional - API Configuration (with defaults)
LIGHTCAST_BASE_URL=https://api.lightcast.io
LIGHTCAST_OAUTH_URL=https://auth.emsicloud.com/connect/token
LIGHTCAST_OAUTH_SCOPE=emsi_open
LIGHTCAST_RATE_LIMIT=1000
# Optional - MCP Server Configuration
MCP_SERVER_NAME=lightcast-mcp-server
LOG_LEVEL=INFO
MASK_ERROR_DETAILS=true
Lightcast API Access
To use this server, you need:
- ๐ A Lightcast API account
- ๐ Client ID and Client Secret for OAuth2 authentication
- ๐ฏ Access to the following Lightcast APIs:
- Titles API - Job title search and normalization
- Skills API - Skills search and categorization
- Classification API - Occupation code mapping
- Similarity API - Skills and occupation relationships
Contact Lightcast for API access and credentials.
๐ฏ Usage
Command Line Interface
The server includes a comprehensive CLI with multiple options:
# Basic usage (uses streamable-http on port 3000 by default)
mcp-lightcast
# Use stdio transport (for Claude Desktop integration)
mcp-lightcast --transport stdio
# Use streamable-http transport with custom port
mcp-lightcast --transport streamable-http --port 8080
# With custom log level
mcp-lightcast --log-level DEBUG
# Validate configuration without starting server
mcp-lightcast --validate-config
# Use custom environment file
mcp-lightcast --env-file /path/to/custom.env
# Quiet mode (no logging)
mcp-lightcast --quiet
# Show help
mcp-lightcast --help
Development Commands
Using the included Makefile for easy development:
# Quick development setup and run
make dev
# Run with debug logging
make dev-server
# Run all quality checks
make check
# Run tests with coverage
make test-coverage
# Show Claude Desktop configuration
make claude-config
Claude Desktop Integration
Using uv (Recommended)
{
"mcpServers": {
"lightcast": {
"command": "uv",
"args": [
"run",
"--directory",
"/path/to/mcp-lightcast",
"mcp-lightcast"
],
"env": {
"LIGHTCAST_CLIENT_ID": "your_client_id",
"LIGHTCAST_CLIENT_SECRET": "your_client_secret"
}
}
}
}
Using Docker
{
"mcpServers": {
"lightcast": {
"command": "docker",
"args": [
"run",
"--rm",
"-i",
"-e", "LIGHTCAST_CLIENT_ID",
"-e", "LIGHTCAST_CLIENT_SECRET",
"ghcr.io/your-org/mcp-lightcast:latest"
],
"env": {
"LIGHTCAST_CLIENT_ID": "your_client_id",
"LIGHTCAST_CLIENT_SECRET": "your_client_secret"
}
}
}
}
Using uvx (Isolated)
{
"mcpServers": {
"lightcast": {
"command": "uvx",
"args": [
"--from",
"mcp-lightcast",
"mcp-lightcast"
],
"env": {
"LIGHTCAST_CLIENT_ID": "your_client_id",
"LIGHTCAST_CLIENT_SECRET": "your_client_secret"
}
}
}
}
๐ ๏ธ Available MCP Tools
๐ฏ Skills Tools
search_skills - Search skills with advanced filters
skills = await search_skills(
query="python programming",
limit=10,
skill_type="Hard Skill", # Optional: filter by skill type
category="Information Technology", # Optional: filter by category
version="latest" # Uses latest API version
)
extract_skills_from_text - Extract skills from job descriptions
# Extract skills with custom confidence threshold
skills = await extract_skills_from_text(
text="Looking for Python developer with React and database experience...",
confidence_threshold=0.7,
version="latest"
)
extract_skills_simple - Extract skills with default settings
# Quick skills extraction with default confidence (0.5)
skills = await extract_skills_simple(
text="We need Java developers with Spring Boot experience",
version="latest"
)
bulk_retrieve_skills - Efficient bulk skill retrieval
# Get multiple skills in one request
skills = await bulk_retrieve_skills(
skill_ids=["KS125LS6N7WP4S6SFTCK", "KS440C66FGP5WGWYMP0F"],
version="latest"
)
๐ท๏ธ Titles Tools
search_job_titles - Search job titles
titles = await search_job_titles(
query="software engineer",
limit=10,
version="latest"
)
get_job_title_details - Get detailed title information
title = await get_job_title_details(
title_id="ET6850661D6AE5FA86",
version="latest"
)
bulk_retrieve_titles - Efficient bulk title retrieval
titles = await bulk_retrieve_titles(
title_ids=["ET6850661D6AE5FA86", "ETBF8AE9187B3810C5"],
version="latest"
)
๐ Metadata Tools
get_skills_version_metadata - API version information
metadata = await get_skills_version_metadata(version="latest")
# Returns: version, skill_count, language_support, skill_types, etc.
get_titles_version_metadata - API version information
metadata = await get_titles_version_metadata(version="latest")
# Returns: version, title_count, removed_title_count, fields
โ ๏ธ Limited Availability Tools
Some tools require premium authentication scopes or have endpoint limitations:
normalize_job_title - โ Requires premium scope
# Currently returns 401 Unauthorized with emsi_open scope
result = await normalize_job_title("sr software dev")
analyze_job_posting_skills - โ Working via skills extraction
# Uses skills extraction instead of normalization
result = await analyze_job_posting_skills(
job_title="Software Engineer",
job_description="Full job description text...",
extract_from_description=True # Uses working skills extraction
)
๐ฏ Example Workflows
1. Extract Skills from Job Description
# Analyze a job posting to extract relevant skills
job_description = """
We're looking for a Senior Software Engineer with expertise in Python,
React, and cloud technologies. Experience with Docker, Kubernetes,
and AWS is required. Strong communication skills and team collaboration
abilities are essential.
"""
# Extract skills with high confidence
skills = await extract_skills_from_text(
text=job_description,
confidence_threshold=0.8,
version="latest"
)
print(f"High-confidence skills found: {len(skills)}")
for skill in skills:
print(f"- {skill['name']} (confidence: {skill['confidence']:.2f})")
2. Compare Skills Across Job Titles
# Search and compare skills requirements for different roles
titles = ["Data Scientist", "Machine Learning Engineer", "Software Engineer"]
title_skills = {}
for title in titles:
# Search for the title
title_results = await search_job_titles(query=title, limit=1)
if title_results:
title_id = title_results[0]['id']
# Get detailed title information
title_details = await get_job_title_details(title_id)
title_skills[title] = title_details
print("Job title comparison completed")
3. Bulk Skills Analysis
# Efficiently analyze multiple skills at once
skill_names = ["Python", "JavaScript", "Machine Learning", "Docker"]
# First search for skill IDs
skill_ids = []
for name in skill_names:
results = await search_skills(query=name, limit=1)
if results:
skill_ids.append(results[0]['id'])
# Get detailed information for all skills in one request
if skill_ids:
detailed_skills = await bulk_retrieve_skills(skill_ids)
for skill in detailed_skills:
print(f"Skill: {skill['name']}")
print(f"Type: {skill.get('type', {}).get('name', 'Unknown')}")
print(f"Category: {skill.get('category', 'Unknown')}")
print("---")
4. API Version and Statistics
# Get comprehensive API information
skills_meta = await get_skills_version_metadata()
titles_meta = await get_titles_version_metadata()
print(f"Skills API v{skills_meta['version']}: {skills_meta['skill_count']:,} skills")
print(f"Languages: {', '.join(skills_meta['language_support'])}")
print(f"Skill types: {len(skills_meta['skill_types'])}")
print(f"Titles API v{titles_meta['version']}: {titles_meta['title_count']:,} titles")
๐งช Development
Prerequisites
- Python 3.12+ (required)
- uv package manager
- Docker (for containerized development)
- Make (for development commands)
Development Setup
# Clone and setup
git clone https://github.com/your-org/mcp-lightcast.git
cd mcp-lightcast
# Quick setup (installs dependencies, creates .env)
make setup
# Install development dependencies only
make install-dev
# Run development server with debug logging
make dev-server
Project Structure
mcp-lightcast/
โโโ ๐ src/mcp_lightcast/ # Main package
โ โโโ __init__.py # CLI entry point with Click
โ โโโ __main__.py # Module execution entry
โ โโโ server.py # FastMCP server instance
โ โโโ ๐ auth/ # Authentication modules
โ โ โโโ __init__.py
โ โ โโโ oauth.py # OAuth2 implementation
โ โโโ ๐ apis/ # API client modules
โ โ โโโ __init__.py
โ โ โโโ base.py # Base client with error handling
โ โ โโโ titles.py # Titles API client
โ โ โโโ skills.py # Skills API client
โ โ โโโ classification.py # Classification API client
โ โ โโโ similarity.py # Similarity API client
โ โโโ ๐ tools/ # MCP tools registration
โ โ โโโ __init__.py
โ โ โโโ titles_tools.py # Title-related MCP tools
โ โ โโโ skills_tools.py # Skills-related MCP tools
โ โ โโโ workflow_tools.py # Combined workflow tools
โ โ โโโ normalize_title_get_skills.py # Core workflow logic
โ โโโ ๐ utils/ # Utility functions
โ โโโ __init__.py
โโโ ๐ tests/ # Test suite
โ โโโ ๐ unit/ # Unit tests
โ โโโ ๐ integration/ # Integration tests
โ โโโ conftest.py # Pytest fixtures
โโโ ๐ config/ # Configuration management
โ โโโ settings.py # Pydantic settings
โโโ ๐ .github/workflows/ # CI/CD pipelines
โ โโโ ci.yml # GitHub Actions workflow
โโโ ๐ณ Dockerfile # Production container
โโโ ๐ณ Dockerfile.dev # Development container
โโโ ๐ณ docker-compose.yml # Multi-service setup
โโโ ๐ Makefile # Development commands
โโโ ๐ฆ pyproject.toml # Project metadata & dependencies
โโโ ๐ uv.lock # Dependency lock file
โโโ ๐ README.md # This file
Development Workflow
Code Quality & Testing
# Run all quality checks (lint + type-check + test)
make check
# Individual quality checks
make lint # Ruff linting
make type-check # MyPy type checking
make format # Black + Ruff formatting
# Testing options
make test # Run all tests
make test-coverage # Tests with coverage report
make test-basic # Basic functionality test
Docker Development
# Build Docker images
make docker-build # Production image
make docker-build-dev # Development image
# Run with Docker
make docker-run # Run production container
make docker-dev # Run development container
# Test Docker configuration
make docker-test # Validate container setup
uv Package Management
# Dependency management
make uv-lock # Generate lockfile
make uv-sync # Sync from lockfile
make uv-update # Update all dependencies
# Add dependencies
make uv-add PACKAGE=requests
make uv-add-dev PACKAGE=pytest-mock
API Reference
Rate Limits
- Default: 1000 requests per hour per API key
- Rate limit headers are included in responses
- Rate limit errors (429) are handled gracefully
Error Handling
- Authentication errors are automatically retried
- Rate limits include reset time information
- API errors include detailed status codes and messages
- Network errors are handled with appropriate timeouts
API Version Flexibility
The MCP server provides flexible version management:
- Default:
"latest"- Always uses the newest available API version - Backward Compatible: Users can specify any previous version (e.g.,
"5.47","9.33") - Future-Proof: Automatically gets new API features when Lightcast releases updates
Examples:
# Use latest version (default)
search_job_titles("software engineer")
# Use specific version for consistency
search_job_titles("software engineer", version="5.47")
# Use older version if needed
search_skills("python", version="9.32")
Current API Versions:
- Skills API:
9.33with 41,139 skills (English, Spanish, French support) - Titles API:
5.47with 73,993 titles - Both APIs use
"latest"keyword for automatic version management
๐ Current Limitations & Future Enhancements
โ ๏ธ Known Limitations (v0.1.0)
Authentication Scope Limitations
- Title Normalization: Requires premium authentication scope (currently 401 Unauthorized)
- Skills Categories: Endpoint not available in current API tier
- Related Skills: Endpoint pattern differs from documentation
Endpoint Coverage
- 61% Coverage: 11 out of 18 planned endpoints working
- Core Functionality: โ All essential features (search, extraction, bulk ops) working
- Premium Features: โ Some advanced features require paid Lightcast tiers
๐ Planned Enhancements
Additional Lightcast APIs
- Classification API: Map concepts to occupation codes (O*NET SOC)
- Similarity API: Find similar occupations and skills
- Occupation Benchmark API: Industry benchmarking and compensation data
- Career Pathways API: Career progression and pathway analysis
- Job Postings API: Real-time job market data and trends
Feature Improvements
- Premium Authentication: Support for advanced Lightcast scopes
- Enhanced Error Handling: Better handling of rate limits and API errors
- Caching Layer: Response caching for improved performance
- Additional Export Formats: CSV, JSON, XML output options
๐ Production Readiness
โ Ready for Production Use:
- Skills extraction from job descriptions
- Skills and titles search functionality
- Bulk data retrieval operations
- API version management and metadata
โ ๏ธ Requires Premium Lightcast Access:
- Job title normalization workflows
- Skills categorization features
- Advanced relationship mapping
Contributing
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
License
This project is licensed under the MIT License - see the LICENSE file for details.
๐ Documentation & Support
API Documentation
- Lightcast API Documentation - Official Lightcast API reference
- FastMCP Documentation - FastMCP framework documentation
- Model Context Protocol - MCP specification
- Testing Summary - Comprehensive endpoint testing results
Project Resources
- PyPI Package - Official Python package
- GitHub Repository - Source code and issues
- GitHub Releases - Version history and changelog
Getting Help
- Issues: GitHub Issues for bugs and feature requests
- Discussions: GitHub Discussions for questions and community support
- Lightcast Support: Contact Lightcast for API access and credentials
Current Status
- Version: 0.1.0 (Production Ready)
- API Coverage: 11/18 endpoints (61%)
- Python: 3.12+ required
- License: MIT
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 mcp_lightcast-0.2.0.tar.gz.
File metadata
- Download URL: mcp_lightcast-0.2.0.tar.gz
- Upload date:
- Size: 133.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
197f4a369d76e0765eb0a251d8786e7e0fd61a12009ad1bf5b0af2c045b38a47
|
|
| MD5 |
deec352487236c219cdfaa0900ff9ae7
|
|
| BLAKE2b-256 |
c71c12422d82f32b2ff4171f6ea04223948ef0061e71c068aa27bae03328f6a6
|
File details
Details for the file mcp_lightcast-0.2.0-py3-none-any.whl.
File metadata
- Download URL: mcp_lightcast-0.2.0-py3-none-any.whl
- Upload date:
- Size: 59.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8382c8ebbc125ba153bb4eb5587d93e07c59c5c2e0412b056ef0db5408407f6d
|
|
| MD5 |
cd48ba70d373fa818bb25bc9a5823e49
|
|
| BLAKE2b-256 |
eb2b3dcae83715f6ab2f2f13f2de8c73c236f58d650a665c9b35b6aa4baaa6fd
|