peoplesoft
Queries and analyzes a local contracts/billing database (PROJECT, CA_DETAIL, CA_BILL_PLAN) via schema introspection, semantic tools, and direct SQL.
README
PeopleSoft MCP Server
A minimal Model Context Protocol (MCP) server, built as a worked example of how an MCP server is constructed. It exposes a local SQLite contracts/billing database (PROJECT, CA_DETAIL, CA_BILL_PLAN) through a small set of tools, ranging from generic schema introspection to purpose-built semantic queries.
Features
- Schema introspection tools — discover tables and columns without any prior knowledge of the schema
- Semantic tools — purpose-built queries for the contracts/billing domain (projects, contract lines, bill plans)
- Direct SQL tool — an escape hatch for arbitrary queries once the schema is known
- Direct database access via Python's stdlib
sqlite3, wrapped inasyncio.to_threadfor async compatibility
Quick Start
Prerequisites
- Python 3.11+
- uv package manager (recommended)
Installation
# Clone the repository
git clone <repo-url>
cd peoplesoft-mcp
# Install dependencies
uv sync
# Create finstg.db and load static data
uv run create_db.py
Configuration
- Copy the example environment file:
cp .env.example .env
- Edit
.envif you want to point at a different SQLite file (defaults tofinstg.dbin the repo root):
SQLITE_DB_PATH=finstg.db
- Copy
.cursor/mcp.json.exampleto.cursor/mcp.jsonand update the path to your installation.
Running the Server
uv run peoplesoft_server.py
Cursor IDE Integration
The MCP config (.cursor/mcp.json, copied from .cursor/mcp.json.example) should look like:
{
"mcpServers": {
"peoplesoft": {
"command": "uv",
"args": [
"--directory",
"/path/to/mcp_ps/",
"run",
"peoplesoft_server.py"
]
}
}
}
Available Tools
Schema Introspection (2 tools)
| Tool | Description |
|---|---|
list_tables |
List tables in the local database, optionally filtered by name |
describe_table |
Get table structure (columns, types, primary keys) |
Contracts & Billing Module (4 tools)
| Tool | Description |
|---|---|
list_projects |
List projects, filterable by business unit/status/type |
get_project_contracts |
Get a project plus its contract lines and bill plans |
list_contracts |
List contract detail lines with their bill plan info |
get_bill_plan |
Get bill plan details for a specific contract line |
Billing Analysis (2 tools)
| Tool | Description |
|---|---|
check_project_billing_setup |
Check each project's contract line(s), bill plan, bill plan type, and effective statuses, to spot billing setup problems |
cost_reimbursable_billable_transactions |
Summarize undistributed cost-reimbursable billable transactions (sums, counts, date range) per project |
Direct Query (1 tool)
| Tool | Description |
|---|---|
query_peoplesoft_db |
Execute custom SQL queries against the local database |
Project Structure
peoplesoft-mcp/
├── peoplesoft_server.py # Main MCP server entry point
├── db.py # SQLite connection management
├── create_db.py # Creates finstg.db and loads data/*.csv
├── db_structure.txt # Schema definition source for create_db.py
├── data/ # Static CSV data loaded into finstg.db
│ ├── project.csv
│ ├── ca_detail.csv
│ ├── ca_bill_plan.csv
│ └── proj_resource.csv
├── finstg.db # Local SQLite database (generated)
├── tools/ # Semantic tool modules
│ ├── introspection.py # Schema discovery tools
│ ├── contracts.py # Contracts/billing tools
│ └── billing.py # Billing setup & cost-reimbursable analysis tools
├── tests/ # Test suite
│ └── test_contracts.py
└── pyproject.toml # Project configuration
Running Tests
uv run pytest tests/ -v -s
Example Queries
- "List all active projects for business unit UCD"
- "What contract lines and bill plans belong to project 25B1111?"
- "What's the bill plan status for contract FAKE4 line 2?"
- "What tables and columns are in finstg.db?"
Development
Adding New Tools
- Create a new module in
tools/or add to an existing module - Define async functions that use
db.execute_query() - Add a
register_tools(mcp)function - Import and register in
peoplesoft_server.py
License
MIT
Changelog
v0.3.0 (2026-07-15)
- Removed the legacy PeopleSoft HCM Oracle tool modules (
hr.py,payroll.py,benefits.py,performance.py,peopletools.py), their docs, their gated/skipped tests, and the Cursor agent/skill configs built around them - Removed the 4 MCP resources that served the now-deleted Oracle-schema documentation
- Repurposed the repo as a standalone worked example of MCP server construction (schema introspection + semantic tools + direct-SQL escape hatch) over a local SQLite database
v0.2.x (2026-03-02 – earlier)
- Replaced Oracle (
oracledb) backend with a local SQLite database (finstg.db) - Rewrote schema introspection to use SQLite's own metadata (
sqlite_master,PRAGMA table_info) - Added
tools/contracts.pywith semantic tools for the localPROJECT/CA_DETAIL/CA_BILL_PLANschema
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
Neon Database
MCP server for interacting with Neon Management API and databases
E2B
Using MCP to run code via e2b.
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.