列出未登记的智能体
读取 MCP 网关见过的调用方,然后将其认定为一个身份,或作为影子智能体继续跟踪。
mcp.shadowidentity.enroll
读取 MCP 网关见过的调用方,然后将其认定为一个身份,或作为影子智能体继续跟踪。
mcp.shadowidentity.enroll出现了无人登记的智能体。经 MCP 网关的每次调用都会留下一个影子事件,写明 DID 和工具。您读取这些事件,把调用方与您的注册表比较,并决定每个调用方是什么。
代码从 INTRAMEDIAL_KEY 读取密钥。请把它放在您的 shell 或密钥存储中,切勿放进要提交的文件。需要已登录用户的调用不能使用密钥:这些调用由控制台发起。
以一个无人登记的智能体身份,经网关路由一次调用。
events 包含最新的 50 条,每条都有 actorDid、tool 和 mode。
{
"events": [
{
"at": "2026-11-01T09:14:02.118Z",
"event": {
"actorDid": ,
: ,
: ,
:
}
}
],
: ,
:
}mcp.shadowmcp-shadowidentity.enrollidentity-enrollcurl -sS -X POST https://api.intramedial.com/api/v1/acp/mcp/enforce \
-H "Authorization: Bearer $INTRAMEDIAL_KEY" \
-H "Content-Type: application/json" \
-d '{
"actorDid": "did:web:unknown.example:agent:scraper",
"tool": "fs.write"
}'const res = await fetch("https://api.intramedial.com/api/v1/acp/mcp/enforce", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.INTRAMEDIAL_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
actorDid: "did:web:unknown.example:agent:scraper",
tool: "fs.write",
}),
});
console.log(res.status, await res.json());import os, requests
res = requests.post(
"https://api.intramedial.com/api/v1/acp/mcp/enforce",
headers={"Authorization": "Bearer " + os.environ["INTRAMEDIAL_KEY"]},
json={
"actorDid": "did:web:unknown.example:agent:scraper",
"tool": "fs.write",
},
timeout=30,
)
print(res.status_code, res.json())该路由返回最新的 50 个事件,含 DID、工具和模式。它不说明调用方是否已登记;请把 DID 与身份列表比较,找出未知的那些。
curl -sS https://api.intramedial.com/api/v1/acp/mcp/shadow \
-H "Authorization: Bearer $INTRAMEDIAL_KEY"const res = await fetch("https://api.intramedial.com/api/v1/acp/mcp/shadow", {
headers: { Authorization: `Bearer ${process.env.INTRAMEDIAL_KEY}`, },
});
const body = await res.json();
for (const { at, event } of body.events) console.log(at, event.actorDid, event.tool, event.mode);import os, requests
res = requests.get(
"https://api.intramedial.com/api/v1/acp/mcp/shadow",
headers={"Authorization": "Bearer " + os.environ["INTRAMEDIAL_KEY"]},
timeout=30,
)
body = res.json()
for e in body["events"]:
print(e["at"], e["event"]["actorDid"], e["event"]["tool"], e["event"]["mode"])以所有者和类型把该 DID 登记为一个身份。之后它会解析为一个智能体,其信任档案从 50 起。
curl -sS -X POST https://api.intramedial.com/api/v1/acp/identity/enroll \
-H "Authorization: Bearer $INTRAMEDIAL_KEY" \
-H "Content-Type: application/json" \
-d '{
"did": "did:web:unknown.example:agent:scraper",
"displayName": "Docs scraper",
"kind": "partner"
}'const res = await fetch("https://api.intramedial.com/api/v1/acp/identity/enroll", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.INTRAMEDIAL_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
did: "did:web:unknown.example:agent:scraper",
displayName: "Docs scraper",
kind: "partner",
}),
});
console.log(res.status, await res.json());import os, requests
res = requests.post(
"https://api.intramedial.com/api/v1/acp/identity/enroll",
headers={"Authorization": "Bearer " + os.environ["INTRAMEDIAL_KEY"]},
json={
"did": "did:web:unknown.example:agent:scraper",
"displayName": "Docs scraper",
"kind": "partner",
},
timeout=30,
)
print(res.status_code, res.json())登记时把 shadow 设为 true,即可跟踪调用方而不予认定。它会连同其所做的每次调用一直显示在列表中,被拒绝的调用方同样保持可见。
curl -sS -X POST https://api.intramedial.com/api/v1/acp/identity/enroll \
-H "Authorization: Bearer $INTRAMEDIAL_KEY" \
-H "Content-Type: application/json" \
-d '{
"did": "did:web:unknown.example:agent:scraper",
"displayName": "Docs scraper",
"kind": "partner",
"shadow": true
}'const res = await fetch("https://api.intramedial.com/api/v1/acp/identity/enroll", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.INTRAMEDIAL_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
did: "did:web:unknown.example:agent:scraper",
displayName: "Docs scraper",
kind: "partner",
shadow: true,
}),
});
console.log(res.status, await res.json());import os, requests
res = requests.post(
"https://api.intramedial.com/api/v1/acp/identity/enroll",
headers={"Authorization": "Bearer " + os.environ["INTRAMEDIAL_KEY"]},
json={
"did": "did:web:unknown.example:agent:scraper",
"displayName": "Docs scraper",
"kind": "partner",
"shadow": True,
},
timeout=30,
)
print(res.status_code, res.json())内容复制自: /docs/mcp-shadow
账本仅可追加,并封存在 Merkle 根之下。条目上的时间取自 Intramedial 自己的时钟,签名包可用已发布的公钥离线核查。
向 MCP 网关请求 Intralock 对智能体工具调用的裁决,读取理由,并列出它已见过的调用方。
mcp.enforce以智能体自己的 DID 为其注册,并附名称和类型,使每项操作都对应到一个智能体。
identity.enroll一次调用读取平面所持有的每个智能体、租约、等待者和隔离项,无需手工维护清单。
coordination.fleetmap当我们向实用示例中添加新示例时,会发送一封简短的邮件。不会发送其他任何邮件,而且您可以从任意一封邮件中退订。
完全无需账户:在 7 天之内可以在各个 attest 路由上调用 35 次,所生成的回执都会被标记为测试回执。当您想继续使用时,再注册账户即可。