npm @m2msentinel/sdkstreamable-httpMITupdated 9d ago
Official multi-language client library, Model Context Protocol (MCP) server, and Coinbase AgentKit ActionProvider for M2M Sentinel — deterministic EVM bytecode capability observations and common-proxy resolution for autonomous applications operating on Base. Callers own transaction policy.
M2M Sentinel 能做什么?
M2M Sentinel SDK & MCP Server
Official multi-language client library, Model Context Protocol (MCP) server, and Coinbase AgentKit ActionProvider for M2M Sentinel — deterministic EVM bytecode capability observations and common-proxy resolution for autonomous applications operating on Base. Callers own transaction policy.
⚡ 1. Model Context Protocol (MCP) Server
Connect M2M Sentinel directly to Claude Desktop, Cursor, Windsurf, or any MCP-compliant LLM agent.
Option A: 1-Click via Smithery
npx -y @smithery/cli mcp add M2M-Sentinel/m2m-sentinel-sdk --client claude
Option B: Local Stdio (claude_desktop_config.json)
{
"mcpServers": {
"m2m-sentinel": {
"command": "npx",
"args": ["-y", "m2m-sentinel-sdk"],
"env": {
"M2M_SENTINEL_API_KEY": ""
}
}
}
}
Option C: Remote Streamable HTTP
- Current MCP endpoint:
https://api.m2msentinel.com/mcp - Legacy HTTP+SSE compatibility:
https://api.m2msentinel.com/ssewith messages athttps://api.m2msentinel.com/messages
🤖 2. Coinbase AgentKit Integration
import { AgentKit } from "@coinbase/agentkit";
import { m2mSentinelActionProvider } from "m2m-sentinel-sdk";
const agentKit = await AgentKit.from({
walletProvider,
actionProviders: [
m2mSentinelActionProvider({
apiKey: process.env.M2M_SENTINEL_API_KEY
})
]
});
📦 3. JavaScript / TypeScript Client
npm install m2m-sentinel-sdk
const { M2MSentinelClient } = require('m2m-sentinel-sdk');
const client = new M2MSentinelClient();
async function main() {
const audit = await client.auditContract('0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913');
console.log('Proxy Detected:', audit.audit.proxyResolution.isProxy);
console.log('Proxy Target:', audit.audit.proxyResolution.targetAddress);
console.log('Capabilities:', audit.audit.verdict.executableCapabilities);
console.log('Evidence:', audit.audit.dissection.capabilities);
}
main().catch(console.error);
🐍 4. Python Client
pip install m2m-sentinel
from m2m_sentinel import M2MSentinelClient
client = M2MSentinelClient()
audit = client.audit_contract("0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913")
print("Proxy detected:", audit["audit"]["proxyResolution"]["isProxy"])
print("Proxy target:", audit["audit"]["proxyResolution"].get("targetAddress"))
print("Capabilities:", audit["audit"]["verdict"]["executableCapabilities"])
print("Evidence:", audit["audit"]["dissection"]["capabilities"])
Transaction-specific preflight example
The public repository includes a standalone, mock-only transaction boundary
example at examples/transaction_preflight.js.
From this repository root, run:
node examples/transaction_preflight.js
It observes one caller-supplied Base transaction, passes the observation to a caller-owned policy, and reaches only a mock signing/send callback. It refuses to continue on unverified evidence, unresolved execution, an observation mismatch, or a missing Diamond selector mapping. It never signs or sends a transaction; optional live mode uses only a caller-supplied API-key header and remains the caller's responsibility.
💳 5. Autonomous x402 Micropayments (Headless M2M)
import { x402SignerClient } from "m2m-sentinel-sdk";
const client = new x402SignerClient({
walletSigner: myAgentWallet,
baseUrl: "https://api.m2msentinel.com"
});
const result = await client.request("/v1/audit/0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913");
📜 License
MIT License. Copyright (c) 2026 M2M Sentinel.
安装
把 M2M Sentinel 添加到你的客户端。选择你正在使用的那个。
{
"servers": {
"sdk": {
"type": "http",
"url": "https://api.m2msentinel.com/mcp"
}
}
}Add to `.vscode/mcp.json` in your workspace.
claude mcp add sdk -- npx -y @m2msentinel/sdkcodex mcp add sdk -- npx -y @m2msentinel/sdkamp mcp add sdk -- npx -y @m2msentinel/sdk{
"mcpServers": {
"sdk": {
"command": "npx",
"args": [
"-y",
"@m2msentinel/sdk"
]
}
}
}Add to `claude_desktop_config.json`, then restart Claude Desktop.
{
"mcpServers": {
"sdk": {
"command": "npx",
"args": [
"-y",
"@m2msentinel/sdk"
]
}
}
}Add to `~/.cursor/mcp.json`, or `.cursor/mcp.json` for a single project.
{
"mcpServers": {
"sdk": {
"command": "npx",
"args": [
"-y",
"@m2msentinel/sdk"
]
}
}
}Add to `~/.codeium/windsurf/mcp_config.json`.
{
"mcpServers": {
"sdk": {
"command": "npx",
"args": [
"-y",
"@m2msentinel/sdk"
]
}
}
}Add to `cline_mcp_settings.json` via the MCP Servers panel.
{
"mcpServers": {
"sdk": {
"command": "npx",
"args": [
"-y",
"@m2msentinel/sdk"
]
}
}
}Add to `~/.gemini/settings.json`.
{
"mcpServers": {
"sdk": {
"type": "local",
"command": "npx",
"args": [
"-y",
"@m2msentinel/sdk"
],
"tools": [
"*"
]
}
}
}Add to `~/.copilot/mcp-config.json`, or run `/mcp add` inside the CLI.
{
"context_servers": {
"sdk": {
"command": {
"path": "npx",
"args": [
"-y",
"@m2msentinel/sdk"
]
}
}
}
}Add to your Zed `settings.json`.
npx -y @m2msentinel/sdkRun `goose configure`, choose **Add Extension → Command-line Extension**, and paste this command.
评分
39 / 100
不完整
- 文档25/25
- 维护19/25
- 可信度16/20
- 能力0/15
- 安装体验15/15
- Documents what it does and how to connect
- Has a resolvable package or endpoint
- Exposes at least one tool, prompt or resource
- README has substantive content
- Includes a code example
- Documents its configuration
- Mentions credentials or security posture
- Last commit 2 days ago
- Has a release history
- Repository is not archived
- Licensed MIT
- Namespace verified in the official MCP registry
- Claimed by its owner
- Published under an organisation
- 0 tool(s) documented
- Provides prompt templates
- Provides resources
- 18 documented install method(s)
- Published to a package registry
- Offers a hosted endpoint — no local install
版本历史
| 版本 | 发布于 |
|---|---|
| 1.2.2最新 | 2026年8月24日 |
| 1.2.1 | 2026年8月24日 |