mirror of
https://github.com/paperclipai/paperclip.git
synced 2026-11-10 12:37:55 +01:00
fix(agents): say who sets up a Claude Managed Agent profile
An agent asked to set up an Anthropic managed agent read the Paperclip Runner configuration doc, which named Claude Managed but not who creates its profile, and spent its reply window exploring hiring and adapter configuration. The doc and the profile-creation catalog entry now say that a board operator creates and qualifies the profile and that agents cannot. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
e83d9bb529
commit
41399e317a
3 files changed
+10
-1
No files matched your search
@@ -5,6 +5,7 @@ import { describe, expect, it } from "vitest";
|
||||
import { errorHandler } from "../middleware/index.js";
|
||||
import { assertBoard, assertBoardOrgAccess, BOARD_ACCESS_REQUIRED_CODE } from "../routes/authz.js";
|
||||
import { AGENT_CHAT_DIRECTIVE } from "../services/agent-conversations.js";
|
||||
import { buildOpenApiDocument } from "../routes/openapi.js";
|
||||
|
||||
const COMPANY_ID = "10000000-0000-4000-8000-000000000001";
|
||||
const AGENT_ID = "20000000-0000-4000-8000-000000000002";
|
||||
@@ -71,4 +72,11 @@ describe("board-only denial", () => {
|
||||
expect(AGENT_CHAT_DIRECTIVE).toContain("tell the person which control in the Paperclip web app to use, link its page when you know the route");
|
||||
expect(AGENT_CHAT_DIRECTIVE).not.toContain("use permitted discovery to identify the supported operator path");
|
||||
});
|
||||
|
||||
it("says in the API catalog who sets up a Claude Managed Agent profile", () => {
|
||||
const post = buildOpenApiDocument().paths["/api/companies/{companyId}/managed-agent-profiles"].post;
|
||||
expect(post["x-paperclip-authorization"]).toEqual({ actor: "board" });
|
||||
expect(post.description).toContain("Board only: agent credentials get 403");
|
||||
expect(post.description).toContain("explicitly acknowledges stateful retention");
|
||||
});
|
||||
});
|
||||
@@ -644,7 +644,7 @@ const paperclipRunnerAdapter: ServerAdapterModule = {
|
||||
)
|
||||
: buildNpmRuntimeCommandSpec(config, "codex", "@openai/codex@0.160.0"),
|
||||
agentConfigurationDoc:
|
||||
"# Paperclip Runner\n\nAdapter: paperclip_runner\n\nRuns Codex, OpenCode, Claude Managed, AWS AgentCore, or ACPX Claude/Grok Build/Cursor/Pi through the Rust Paperclip runner and authenticated PRP transport. Pi accepts an explicit provider/model ID and uses the company credentials bound to the agent environment. GitHub Copilot requires a saved GitHub token and an explicitly selected available model. Managed providers use company-scoped qualified profiles, explicit retention acknowledgement, and spend limits.\n",
|
||||
"# Paperclip Runner\n\nAdapter: paperclip_runner\n\nRuns Codex, OpenCode, Claude Managed, AWS AgentCore, or ACPX Claude/Grok Build/Cursor/Pi through the Rust Paperclip runner and authenticated PRP transport. Pi accepts an explicit provider/model ID and uses the company credentials bound to the agent environment. GitHub Copilot requires a saved GitHub token and an explicitly selected available model. Managed providers use company-scoped qualified profiles, explicit retention acknowledgement, and spend limits. A board operator creates each Claude Managed (Anthropic managed agent) profile through POST /api/companies/{companyId}/managed-agent-profiles; agent credentials cannot create, qualify or list one.\n",
|
||||
getConfigSchema: () => ({
|
||||
fields: [
|
||||
{
|
||||
|
||||
@@ -7570,6 +7570,7 @@ registry.registerPath({
|
||||
path: "/api/companies/{companyId}/managed-agent-profiles",
|
||||
tags: ["agents"],
|
||||
summary: "Create or operator-attest a Claude Managed Agent profile",
|
||||
description: "Board only: agent credentials get 403. A Claude Managed Agent runs on Anthropic's managed-agents beta. A board operator creates the company profile with an Anthropic API-key secret and a limited environment (no hosts, no packages), attests its qualification and explicitly acknowledges stateful retention before it can be enabled.",
|
||||
request: {
|
||||
params: z.object({ companyId: z.string() }),
|
||||
body: jsonBody(
|
||||
|
||||
Reference in new issue
Block a user