Skip to main content

Mage Agent unified MCP/CLI tooling

Project description

mage-agent

Phase 1 status

Implemented:

  • Python package scaffold with mage-agent entrypoint
  • MCP stdio runtime (mage-agent mcp)
  • Shared core config/auth/http/error modules
  • Tools layer (Python API wrappers) for pipeline CRUD, block operations, run trigger, and log retrieval

Local setup

python -m venv .venv
source .venv/bin/activate
python -m pip install --upgrade pip
pip install -e ".[dev]"

Configure credentials (recommended)

Use interactive login:

mage-agent login

Or provide values non-interactively:

mage-agent login \
  --cluster-url https://your-mage-url \
  --email YOUR_EMAIL \
  --password YOUR_PASSWORD \

login authenticates with the cluster URL using username/password, then writes ~/.mage-agent/config.json with your cluster_url and oauth_token. The agent uses a built-in default API key for requests.

Authentication gates runtime functionality: MCP tool calls require valid auth credentials.

Configure credentials (manual option)

Create ~/.mage-agent/config.json:

{
  "cluster_url": "https://your-mage-url",
  "oauth_token": "RAW_OAUTH_TOKEN"
}

Optional developer tooling

Dev tooling (flake8, pre-commit) is defined in pyproject.toml under optional dependency group dev. If you installed with pip install -e ".[dev]", run local checks with:

flake8 src
pre-commit run --all-files

Run MCP server

mage-agent mcp

Install and connect from IDEs

After installing mage-agent and running mage-agent login, configure your IDE/agent client to launch the MCP server with:

  • command: mage-agent
  • args: ["mcp"]

If mage-agent is not on PATH in the client runtime, use the absolute path to the executable.

Sync project to local files

mage-agent sync-project-to-local --local-project-dir .mage-agent/local_sync

If --local-project-dir is not provided, the CLI prompts for it.

Connect Cursor to MCP

  1. Open Cursor settings and go to MCP servers.
  2. Add a new server named mage-agent.
  3. Use this command configuration:
{
  "mcpServers": {
    "mage-agent": {
      "command": "mage-agent",
      "args": ["mcp"]
    }
  }
}

If mage-agent is not on your PATH in Cursor, use the full executable path instead:

{
  "mcpServers": {
    "mage-agent": {
      "command": "/absolute/path/to/mage-agent",
      "args": ["mcp"]
    }
  }
}

After saving the config, reload Cursor and confirm the mage-agent MCP tools are available.

Connect Codex CLI to MCP

Add mage-agent to Codex MCP config (for example in your Codex config file):

{
  "mcpServers": {
    "mage-agent": {
      "command": "mage-agent",
      "args": ["mcp"]
    }
  }
}

Then restart Codex CLI and verify tools/resources are visible.

Connect Claude Code to MCP

Configure MCP servers in Claude Code with the same command:

{
  "mcpServers": {
    "mage-agent": {
      "command": "mage-agent",
      "args": ["mcp"]
    }
  }
}

Restart Claude Code after saving config, then run a simple MCP call (for example pipeline_list) to verify connectivity.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mage_agent-0.1.0.tar.gz (25.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mage_agent-0.1.0-py3-none-any.whl (30.1 kB view details)

Uploaded Python 3

File details

Details for the file mage_agent-0.1.0.tar.gz.

File metadata

  • Download URL: mage_agent-0.1.0.tar.gz
  • Upload date:
  • Size: 25.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for mage_agent-0.1.0.tar.gz
Algorithm Hash digest
SHA256 b31a837ea36e523a6ac7c85e6e0b3fc44e770cf25c7a9ff2e50dd59ef924d463
MD5 8e081f470f3ee9f0b0c622208a323d34
BLAKE2b-256 fe07e34a6ab3a77e1cd582d525a7cd987b4c09a0f1576dc49195bc5e6e681ed6

See more details on using hashes here.

Provenance

The following attestation bundles were made for mage_agent-0.1.0.tar.gz:

Publisher: publish.yml on mage-ai/mage-agent

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file mage_agent-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: mage_agent-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 30.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for mage_agent-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 170080a253a54b455beeab4a97d270d3bd67a868fa34f08b47d88e16ed00baf0
MD5 c2fa02c2b990e759c04afeb9833f95b3
BLAKE2b-256 44ee27b5258a7874b44e8c5d6cb4d0cdc0590bdd442f63a4f7141ba0cd38dab5

See more details on using hashes here.

Provenance

The following attestation bundles were made for mage_agent-0.1.0-py3-none-any.whl:

Publisher: publish.yml on mage-ai/mage-agent

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page