Skip to main content

openclaw-sap-gate

Python reference implementation of SAP/1.0 — SAFE Authorization Protocol for MCP tool calls.

pip install openclaw-sap-gate

Usage

from openclaw_sap_gate import authorized, require_authorized

# Check (returns bool)
if not authorized("my-app"):
    return "denied"

# Assert (raises PermissionError on failure)
require_authorized("my-app")

CLI

# Verify an app_id passes the full auth chain
sap-gate verify my-app

# Scaffold a new SAFE folder + manifest template
sap-gate init my-app

Configuration

Env var Default Description
SAP_SAFE_ROOT ~/.sap/Applications Root directory for SAFE folders
SAP_PGP_FINGERPRINT (empty — any valid sig passes) Pinned primary key fingerprint
SAP_LOG_DIR ~/.sap/log Directory for gaps.jsonl and grants.jsonl

How It Works

Authorization requires all four steps:

  1. SAP_SAFE_ROOT/<app_id>/ exists
  2. safe-app-manifest.json present and readable
  3. safe-app-manifest.json.sig present
  4. gpg --verify passes, signer fingerprint matches SAP_PGP_FINGERPRINT

Revoke by deleting the folder or .sig file.

OpenClaw Enforcement Skill

→ rudi193-cmd/openclaw-skill-sap

Protocol Spec

→ SAP/1.0 RFC

License

MIT — Sean Campbell 2026

Metadata

Release files for openclaw-sap-gate 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 openclaw-sap-gate 1.0.0
File Size Uploaded Provenance
openclaw_sap_gate-1.0.0.tar.gz 5.8 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for openclaw-sap-gate 1.0.0
File Interpreter ABI Platform
openclaw_sap_gate-1.0.0-py3-none-any.whl Python 3 none any Details

Total release size: 12.5 kB

Release files / openclaw_sap_gate-1.0.0.tar.gz

Download URL openclaw_sap_gate-1.0.0.tar.gz
Size 5.8 kB
Tags Source
SHA-256 checksum
How to use checksums
229f77e9188de527e63e617535056b9074e1f07a66901c037e1957b56c5b0174
BLAKE2b-256 checksum
How to use checksums
2079e0f7b6bbf5b4e35562dadb9071101beeee70972ce8a9c88a68a0858b21ae
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.7

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

Download URL openclaw_sap_gate-1.0.0-py3-none-any.whl
Size 6.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
6c98b50fcb9af9290fd0173efb06a868e109df9f227c731755b780f5b3751acc
BLAKE2b-256 checksum
How to use checksums
349650fa3a242958b6564f0384506ecaa615a43b16f699329e1b349c9303ead6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.7

Security for openclaw-sap-gate 1.0.0

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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.0.0 This release

2 release files No provenance

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