Skip to main content

Watchlight MCP Runtime PEP

A Policy Enforcement Point for the Model Context Protocol. It sits in front of an upstream MCP server and makes one guarantee:

No governed MCP action reaches the target system until Watchlight has made a deterministic runtime authorization decision — and only an explicit PERMIT forwards it.

Every tools/call is authorized in-process by the real Watchlight engine before it can reach the upstream server. A denied call is blocked before it executes — not detected after. Zero infrastructure: no database, no network hop, no sidecar.

Install

pip install watchlight-mcp

Run

import watchlight_mcp

watchlight_mcp.serve(
    listen_addr="127.0.0.1:9700",
    upstream_url="http://localhost:3000/mcp",   # the MCP server you are governing
    upstream_server="github",                    # a stable name for it (used in policy + audit)
    policy_files=["policies/allow-read.json"],   # Cedar policies, wl-apdp shape
    audit_path="audit/mcp-pep.jsonl",            # value-free JSONL audit (omit → logs)
)

Point your MCP client at http://127.0.0.1:9700/mcp instead of the server directly. Governed tools/calls are authorized; everything else is forwarded transparently.

What it enforces

  • MCP 2026-07-28 Streamable HTTP: the JSON-RPC body is authoritative, and the Mcp-Method / Mcp-Name / MCP-Protocol-Version routing headers are validated against it — a spoofed header cannot route a governed call around enforcement.
  • Fail-closed: a deny, a runtime error, a malformed body, a header/body mismatch, or an unsupported protocol version all block the action. The upstream is contacted only on an explicit permit.
  • Value-free audit: the audit record has no field for tool arguments, tokens, or credentials — only the decision and safe correlation ids.

Identity

The PEP reads client-asserted Watchlight-* headers (Watchlight-Agent-Id, Watchlight-Execution-Id, …) to build the authorization principal and execution context — the Developer-Edition trust model. Without an attributed agent, the action is denied by default.


© Watchlight AI. The embedded runtime is proprietary; see LICENSE.

Release files for watchlight-mcp 0.3.0

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

Built distributions (wheels)

Table of built distributions (wheels) for watchlight-mcp 0.3.0
File
watchlight_mcp-0.3.0-cp39-abi3-manylinux_2_28_aarch64.whl CPython 3.9 abi3 Linux glibc 2.28+ ARM64 Details
watchlight_mcp-0.3.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.9 abi3 Linux glibc 2.17+ x86-64 Details
watchlight_mcp-0.3.0-cp39-abi3-macosx_11_0_arm64.whl CPython 3.9 abi3 macOS 11.0+ ARM64 Details
watchlight_mcp-0.3.0-cp39-abi3-macosx_10_12_x86_64.whl CPython 3.9 abi3 macOS 10.12+ x86-64 Details

Total release size: 21.7 MB

Release files / watchlight_mcp-0.3.0-cp39-abi3-manylinux_2_28_aarch64.whl

Download URL watchlight_mcp-0.3.0-cp39-abi3-manylinux_2_28_aarch64.whl
Size 5.3 MB
Tags CPython 3.9 Linux glibc 2.28+ ARM64 abi3
SHA-256 checksum
How to use checksums
e0ebc33eba9357f48e1131cf421d10ff566c174543349ccdcdde245892fd3d9e
BLAKE2b-256 checksum
How to use checksums
80cca83d975161784ffa9c7ded92d9f15287084d5aefd844d36c84799122cffb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 28, 2026.

Transparency log

Release files / watchlight_mcp-0.3.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL watchlight_mcp-0.3.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 5.7 MB
Tags CPython 3.9 Linux glibc 2.17+ x86-64 abi3
SHA-256 checksum
How to use checksums
9e82ea5afffe923c562acb13f5f7ecfbe7b4b7968c5ab723c1e9fcc30448c9ea
BLAKE2b-256 checksum
How to use checksums
67d879c186b5b15615fc5e86d9279fdec86e072dc27bd7320296b5570e560302
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 28, 2026.

Transparency log

Release files / watchlight_mcp-0.3.0-cp39-abi3-macosx_11_0_arm64.whl

Download URL watchlight_mcp-0.3.0-cp39-abi3-macosx_11_0_arm64.whl
Size 5.2 MB
Tags CPython 3.9 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
2c134e76ab617469420b0ba2d076666078f7628e2787e9b4a598ddc678a6a006
BLAKE2b-256 checksum
How to use checksums
34e8d02e7c50b10d2194e3fcc1a37dd826cfddbdb03e7076fe3b3eaabf1a7881
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 28, 2026.

Transparency log

Release files / watchlight_mcp-0.3.0-cp39-abi3-macosx_10_12_x86_64.whl

Download URL watchlight_mcp-0.3.0-cp39-abi3-macosx_10_12_x86_64.whl
Size 5.5 MB
Tags CPython 3.9 abi3 macOS 10.12+ x86-64
SHA-256 checksum
How to use checksums
3ac1238de03de78eb2b04992cad292d200c3dd8572a6edee2ef314326aa9488a
BLAKE2b-256 checksum
How to use checksums
231a7a41360eca6ee6e30d7ac583d50a9aafb7259b2b4f99e5f6e53db43b47d3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 28, 2026.

Transparency log

Release history Release notifications | RSS feed

0.4.3

4 release files

0.4.2

4 release files

0.4.1

4 release files

0.4.0

4 release files

This release

0.3.0 This release

4 release files

0.2.1

4 release files

0.2.0

4 release files

0.1.0

4 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