<!--
Copyright 2025 Orkes Inc.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on
an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the
specific language governing permissions and limitations under the License.
-->
# oss-conductor-mcp
Model Context Protocol server for OSS Conductor.

# Running the server
This project relies on `uv` https://docs.astral.sh/uv/getting-started/

Create venv (not entirely necessary, since `uv` automatically creates and uses the virtual environment on its own when running other commands)
```commandline
uv sync
source .venv/bin/activate
```
Run Server
```commandline
uv run server.py
```
---
For local development, a `local_development.py` file is provided for convenience for setting environment variables explicitly.

This is particularly useful where you don't have control over the environment, i.e. running in Claude.
```
    os.environ[CONDUCTOR_SERVER_URL] = 'https://developer.orkescloud.com/api'
    os.environ[CONDUCTOR_AUTH_KEY] = '<YOUR_APPLICATION_AUTH_KEY>'
    os.environ[CONDUCTOR_AUTH_SECRET] = '<YOUR_APPLICATION_SECRET_KEY>'
```
To run with local development add 'local_dev' to the server arguments:
```commandline
uv run server.py local_dev
```
> Note: the `/api` path is required as part of the CONDUCTOR_SERVER_URL for most applications
# Adding to Claude
Follow [this tutorial](https://modelcontextprotocol.io/quickstart/user) for adding the mcp server to claude, and use the following
configuration, with or without the `local_dev` argument:
```json
{
  "mcpServers": {
    "conductor": {
      "command": "uv",
      "args": [
        "--directory",
        "/<YOUR ABSOLUTE PATH TO THE DIRECTORY CONTAINING server.py>",
        "run",
        "server.py",
        "local_dev"
      ]
    }
  }
}
```
After adding this configuration, Claude must be restarted to pick up the new MCP server.

> Note: alternatively you can use the absolute path to the project root and use 'conductor-mcp' instead of 'server.py'

# Adding to Cursor
The main Cursor instructions are [here](https://docs.cursor.com/context/model-context-protocol).
Go to `Cursor -> Settings -> Cursor Settings -> MCP` and select "+ Add new global MCP server".

Here you can add the exact same configuration file shown in the example for Claude (above).
You can then access the AI chat feature and explore the MCP server in the [sidebar with ⌘+L (Mac) or Ctrl+L (Windows/Linux)](https://docs.cursor.com/chat/overview).