Skip to main content

Trust-gated MCP server wrapper for OpenAI Agents SDK via Dominion Observatory

Project description

openai-agents-trust-gate

PyPI License: MIT

Trust-gated MCP server wrapper for OpenAI Agents SDK. Wraps any MCPServer to check behavioral trust scores via Dominion Observatory before every tool call.

Install

pip install openai-agents-trust-gate

Quick Start

from agents.mcp import MCPServerStreamableHttp
from openai_agents_trust_gate import TrustGatedMCPServer

raw_server = MCPServerStreamableHttp(url="https://example.com/mcp")
server = TrustGatedMCPServer(raw_server, min_score=70)

agent = Agent(
    name="my-agent",
    mcp_servers=[server],  # Trust-gated automatically
)

How It Works

  1. Wraps any MCPServer, intercepting call_tool() at the MCP layer
  2. Before each tool call, checks the server trust score via Dominion Observatory
  3. Blocks calls to servers below the threshold
  4. Reports outcomes back to the Observatory
  5. Scores are cached (5-minute TTL) for performance

Configuration

TrustGatedMCPServer(
    inner_server,
    min_score=70,           # Minimum trust score (0-100)
    cache_ttl=300.0,        # Cache TTL in seconds
    block_on_error=False,   # Fail-open if Observatory unreachable
    report_outcomes=True,   # Report call outcomes back
)

License

MIT

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

openai_agents_trust_gate-0.1.0.tar.gz (4.7 kB view details)

Uploaded Source

Built Distribution

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

openai_agents_trust_gate-0.1.0-py3-none-any.whl (5.8 kB view details)

Uploaded Python 3

File details

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

File metadata

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

File hashes

Hashes for openai_agents_trust_gate-0.1.0.tar.gz
Algorithm Hash digest
SHA256 12c9ff8d1447a51d0fb45e5a1fb66a72b3486932409c59037dc835462ca6e12f
MD5 556cf80fd0faeaefb6d70ea201acfdf9
BLAKE2b-256 12622525b7894efe1199799bb1b73364426859675519f52c4b7825ff4599e4b8

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for openai_agents_trust_gate-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 73ef519736ceeecfe0e82d73a1001242a8e382e8937f55c08020619e91c9d8ee
MD5 50ff24d822f1dd5448775e449245df5c
BLAKE2b-256 24d9c1869e06b468ec19b8a060bf3820ea1d9c42c5b0c7b23d94a4d87c1d689a

See more details on using hashes here.

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