Skip to main content

aigp-mcp

AIGP governance for MCP (Model Context Protocol) tool invocations.

Part of MAIGP — the Mediated AI Governance Protocol: a runtime consent / scope / evidence layer for AI systems. Every governed call is CHECKed before it runs (policy, scope, jurisdiction, circuit-breaker) and RECORDed + TRACEd as tamper-evident evidence after.

What it governs

Governs MCP tool calls — policy, scope, consent, classification, and evidence.

Governance model

This adapter maps the framework's lifecycle onto the AIGP agent-governance loop provided by maigp-agent-core:

Framework event AIGP action
run / invocation start CHECK (pre_invoke) — allowed? under what authority?
each model reply token accounting (on_model_call)
each tool / function call tool governance (on_tool_call)
run complete RECORD + TRACE (post_invoke)
failure on_error (recorded, then re-raised)

Install

pip install aigp-mcp

Pulls in maigp-agent-core (shared lifecycle) and, transitively, maigp-client.

Quick start

from aigp_mcp import GovernedMCPClient, MCPGovernanceConfig

config = MCPGovernanceConfig(
    mode="ENFORCE",
    gov_url="https://gov.example.com",
    app_id="mcp-gateway",
    hmac_secret="...",
)
governed = GovernedMCPClient(mcp_client, config)

# Pre-check → execute only if allowed → post-record evidence
result = await governed.call_tool("wiz", "listVulnerabilities",
                                  {"severity": "HIGH"})

Modes & exports

mode="ENFORCE" blocks disallowed calls (raising GovernanceDenied); monitor-only modes record without blocking. Exports include AccessDecision, GovernanceDenied, and ToolEvidence.


License: Proprietary. © Kanjani AI Research & Causum.

Metadata

Release files for aigp-mcp 1.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for aigp-mcp 1.0.0
File Size Uploaded
aigp_mcp-1.0.0.tar.gz 11.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for aigp-mcp 1.0.0
File Interpreter ABI Platform
aigp_mcp-1.0.0-py3-none-any.whl Python 3 none any Details

Total release size: 21.8 kB

Release files / aigp_mcp-1.0.0.tar.gz

Download URL aigp_mcp-1.0.0.tar.gz
Size 11.5 kB
Tags Source
SHA-256 checksum
How to use checksums
bed62d1fbe4084f43828d8c28f53d4fb7258b8572aa68a41c444f5b5aa96247b
BLAKE2b-256 checksum
How to use checksums
908c9eef151af3a754d6dab8a0c4d88e1699ae37c6d99257ec564acbc9afa4b7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / aigp_mcp-1.0.0-py3-none-any.whl

Download URL aigp_mcp-1.0.0-py3-none-any.whl
Size 10.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
8eb092a80262ef951010ed37d8e213f24d2722ea246b04c13aa34186d4360571
BLAKE2b-256 checksum
How to use checksums
c91b47caf9d4e6d5993cee9ce6df85a91a252b683faaedc29555a3e7ab5dde6a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release history Release notifications | RSS feed

This release

1.0.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page