The Agent Security API protects AI agents by validating tool calls before execution and detecting anomalous behavior patterns.Project Scoping: Agent profiles are scoped by project. For the Developer API, project_id is automatically extracted from your API key. For the Consumer API, project_id must be provided in the request body.
Note: For Developer API, project_id is automatically extracted from your API key. For Consumer API, include project_id in the request body.Response (Allowed) (from staging, 2026-10-31)
Response (Needs review): the same call with "tool_name": "write_file" and a content argument. write_file is on the default review list, so it is not allowed until a person approves it:
Response (Blocked): "tool_name": "run_command", which is on the default blocked list:
{ "allowed": false, "risk_score": 1.0, "risk_level": "critical", "reason": "Tool 'run_command' is blocked for security reasons", "warnings": ["blocked_tool"], "blocked_reasons": ["Tool 'run_command' is blocked for security reasons"]}
The agent’s behaviour profile can add to a verdict: an unusual pattern for this agent_id appears in warnings and as an Anomaly detected: ... entry in blocked_reasons.
active_sessions is always 0 and is marked deprecated in the API schema. PromptGuard does not retain agent session state across requests, so there is nothing to count. The field is scheduled for removal in the next API version — do not build on it.
An agent’s policy — allowed_tools, blocked_tools, require_approval —
decides validate-tool verdicts only while the project’s
agent_policy_enforced setting is on. It is off by default: policies you
write are shown on the dashboard’s Agent Security page and enforce nothing
until you turn enforcement on there, or via the dashboard API:
The project response carries the current value. While enforcement is off,
every agent gets the platform-default tool lists. When it is on, an empty
allowed_tools means no allowlist is configured (the defaults stand), a
non-empty one replaces the default allowlist, and blocked_tools is added to
the platform defaults — a policy can narrow what an agent may do, never
re-enable a dangerous default.
This endpoint is a no-op. Server-side agent session state is not retained across requests, so there is no session to end. The route still returns 200 with the same keys as before plus "deprecated": true, and sends Deprecation: true and Sunset: Wed, 09 Dec 2026 00:00:00 GMT. It will be removed on or after that sunset date — stop calling it.
Get the org-managed update policy for an enrolled device (used by the desktop agent to apply fleet-managed update settings).
GET /api/v1/agent/managed-policy
This poll doubles as the device’s heartbeat: each call updates the device’s Last seen in the fleet view. A device that shows never has enrolled but has not yet polled — check that the agent is installed and running on that machine.Response
Agent profiles are isolated by project. This means:
The same agent_id in different projects will have separate behavioral profiles
Profiles persist across restarts (stored in database)
Each project maintains its own baseline for anomaly detection
Developer API: project_id is automatically extracted from your API key. Ensure your API key is associated with a project.Consumer API: Include project_id in your request body. You must have access to the specified project.
Validate every tool call: Don’t skip validation for “safe” tools
Use sessions: Group related calls for better behavior analysis
Review anomalies: Investigate calls whose blocked_reasons include Anomaly detected
Set up alerts: Monitor for patterns indicating compromise
Use project-scoped API keys: Ensure your API keys are associated with projects for proper isolation
Last modified on November 1, 2026
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"PromptGuard","description":"AI security firewall. Protect LLM applications from prompt injection, data leaks, jailbreaks, and PII exposure.","colors":{"primary":"#3B82F6","light":"#60A5FA","dark":"#1D4ED8"},"logo":{"light":"https://mintcdn.com/promptguard/sBVZPqZYn263LC-L/logo/light.svg?fit=max\u0026auto=format\u0026n=sBVZPqZYn263LC-L\u0026q=85\u0026s=8bf0b3b1f4e6fcd571bd4fefce2cda92","dark":"https://mintcdn.com/promptguard/sBVZPqZYn263LC-L/logo/dark.svg?fit=max\u0026auto=format\u0026n=sBVZPqZYn263LC-L\u0026q=85\u0026s=5448b21f857c43e1208ae10e3d2b09e7","href":"https://promptguard.co"},"favicon":{"light":"https://mintcdn.com/promptguard/spb60-yqv9beaOFS/favicon.ico?fit=max\u0026auto=format\u0026n=spb60-yqv9beaOFS\u0026q=85\u0026s=ccf87036090bd89bb275dd47d8e66cac","dark":"https://mintcdn.com/promptguard/spb60-yqv9beaOFS/favicon.ico?fit=max\u0026auto=format\u0026n=spb60-yqv9beaOFS\u0026q=85\u0026s=ccf87036090bd89bb275dd47d8e66cac"},"api":{"playground":{"display":"interactive"},"mdx":{"server":"https://api.promptguard.co"}},"background":{"decoration":"gradient"},"navbar":{"links":[{"href":"https://promptguard.co/contact","label":"Support"}],"primary":{"type":"button","label":"Get API Key","href":"https://app.promptguard.co"}},"footer":{"socials":{"twitter":"https://x.com/PromptGuardco","linkedin":"https://www.linkedin.com/company/promptguardco"},"links":[{"items":[{"label":"Dashboard","href":"https://app.promptguard.co"},{"label":"Pricing","href":"https://promptguard.co/pricing"},{"label":"Changelog","href":"/changelog"}]},{"items":[{"label":"Quick Start","href":"/quickstart"},{"label":"API Reference","href":"/api-reference/introduction"},{"label":"Python SDK","href":"/guides/python-sdk"},{"label":"Node.js SDK","href":"/guides/node-sdk"},{"label":"CLI","href":"/tools/cli"}]},{"items":[{"label":"Blog","href":"https://promptguard.co/blog"},{"label":"Support","href":"https://promptguard.co/contact"},{"label":"Terms","href":"https://promptguard.co/terms"},{"label":"Privacy","href":"https://promptguard.co/privacy"}]},{"items":[{"label":"llms.txt","href":"https://docs.promptguard.co/llms.txt"},{"label":"llms-full.txt","href":"https://docs.promptguard.co/llms-full.txt"}]}]},"search":{},"seo":{"metatags":{"og:type":"website","og:site_name":"PromptGuard Docs"},"indexing":"navigable"},"styling":{"eyebrows":"breadcrumbs","codeblocks":"system","latex":true},"contextual":{"options":["copy","chatgpt","claude","perplexity","add-mcp","cursor","vscode"],"display":"header"},"interaction":{"drilldown":true},"metadata":{"timestamp":true},"navigation":{"global":{"anchors":[{"anchor":"Dashboard","icon":"rectangle-terminal","href":"https://app.promptguard.co"},{"anchor":"Blog","icon":"newspaper","href":"https://promptguard.co/blog"}]},"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"promptguard","hasAudioNarration":false,"actualSubdomain":"promptguard","customDomains":["docs.promptguard.co"],"gitSource":{"type":"github","owner":"promptguardhq","repo":"promptguard","deployBranch":"main","contentDirectory":"apps/docs","isPrivate":true,"mountPath":"","label":"","_id":"6ae67b21a8f9aedbcd15e200"},"chroma":{"liveDeploymentHistoryId":"6ae777b052c8551247d82fc9","collectionId":"c72ab137-f46b-445e-af33-af4fce74895c","schemaVersion":"v3","latestBuiltDeploymentHistoryId":"6ae777b052c8551247d82fc9"},"entitlements":{},"buildId":"6ae777b052c8551247d82fc9","clientVersion":"0.0.4044","searchFilterCounts":[{"language":"default","tag":"Documentation","count":115},{"language":"default","tag":"API Reference","count":72},{"language":"default","tag":"Integrations","count":22},{"language":"default","tag":"Shadow AI","count":14},{"language":"default","tag":"LLM Providers","count":13},{"language":"default","tag":"Core Concepts","count":13},{"language":"default","tag":"Platform","count":12},{"language":"default","tag":"Resources","count":11},{"language":"default","tag":"Gateway","count":9},{"language":"default","tag":"Going to Production","count":9}]},"assistantConfig":{},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"byok-sep-25","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"vite-origin","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-updated-9-15","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[{"filePath":"style.css","content":"#banner{background:linear-gradient(135deg,#1e3a5f 0,#1d4ed8 50%,#3b82f6 100%)}#banner a{color:#93c5fd;text-decoration:underline;text-underline-offset:2px}#banner a:hover{color:#bfdbfe}"}],"page":{"pagePath":"api-reference/agent-security","slug":"/api-reference/agent-security","pageMetadata":{"title":"Agent Security API","description":"Agent Security API — validate tool calls and monitor agent behaviour.","href":"/api-reference/agent-security"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Agent Security API — validate tool calls and monitor agent behaviour.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={code:`code`,li:`li`,ol:`ol`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,ul:`ul`,..._provideComponents(),...props.components},{CodeBlock,Heading,Tab,Table,Tabs,Warning}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Tab)_missingMdxReference(`Tab`,true);if(!Table)_missingMdxReference(`Table`,true);if(!Tabs)_missingMdxReference(`Tabs`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsx(Heading,{level:`1`,id:`agent-security-api`,children:`Agent Security API`}),`\n`,_jsx(_components.p,{children:`The Agent Security API protects AI agents by validating tool calls before execution and detecting anomalous behavior patterns.`}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Project Scoping`}),`: Agent profiles are scoped by project. For the Developer API, `,_jsx(_components.code,{children:`project_id`}),` is automatically extracted from your API key. For the Consumer API, `,_jsx(_components.code,{children:`project_id`}),` must be provided in the request body.`]}),`\n`,_jsx(Heading,{level:`2`,id:`why-agent-security`,children:`Why Agent Security?`}),`\n`,_jsx(_components.p,{children:`AI agents with tool access can be exploited to:`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Execute dangerous commands`}),`: Shell injection, file system manipulation`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Escalate privileges`}),`: Accessing restricted resources`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Exfiltrate data`}),`: Sending data to external endpoints`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Behave erratically`}),`: Unusual patterns indicating compromise`]}),`\n`]}),`\n`,_jsx(Heading,{level:`2`,id:`endpoints`,children:`Endpoints`}),`\n`,_jsx(Heading,{level:`3`,id:`validate-tool-call`,children:`Validate Tool Call`}),`\n`,_jsx(_components.p,{children:`Validate a tool call before allowing execution.`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`http`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`http`,children:_jsxs(_components.code,{language:`http`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`POST`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` /api/v1/agent/validate-tool`})]}),`\n`]})})}),`\n`,_jsx(_components.p,{children:_jsx(_components.strong,{children:`Request Body`})}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`8`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`8`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"agent_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"agent-123\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"tool_name\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"read_file\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"arguments\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"path\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"/tmp/output.txt\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"session_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"session-456\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Note`}),`: For Developer API, `,_jsx(_components.code,{children:`project_id`}),` is automatically extracted from your API key. For Consumer API, include `,_jsx(_components.code,{children:`project_id`}),` in the request body.`]}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Response (Allowed)`}),` (from staging, 2026-10-31)`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`8`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`8`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"allowed\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`true`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"risk_score\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`0.0`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"risk_level\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"safe\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"reason\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Tool call approved\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"warnings\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [],`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"blocked_reasons\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: []`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Response (Needs review)`}),`: the same call with `,_jsx(_components.code,{children:`\"tool_name\": \"write_file\"`}),` and a `,_jsx(_components.code,{children:`content`}),` argument. `,_jsx(_components.code,{children:`write_file`}),` is on the default review list, so it is not allowed until a person approves it:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`8`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`8`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"allowed\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`false`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"risk_score\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`0.0`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"risk_level\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"medium\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"reason\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Tool call requires human review\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"warnings\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [],`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"blocked_reasons\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Tool call requires human review\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`]`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Response (Blocked)`}),`: `,_jsx(_components.code,{children:`\"tool_name\": \"run_command\"`}),`, which is on the default blocked list:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`8`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`8`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"allowed\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`false`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"risk_score\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`1.0`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"risk_level\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"critical\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"reason\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Tool 'run_command' is blocked for security reasons\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"warnings\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"blocked_tool\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`],`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"blocked_reasons\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Tool 'run_command' is blocked for security reasons\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`]`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`The agent’s behaviour profile can add to a verdict: an unusual pattern for this `,_jsx(_components.code,{children:`agent_id`}),` appears in `,_jsx(_components.code,{children:`warnings`}),` and as an `,_jsx(_components.code,{children:`Anomaly detected: ...`}),` entry in `,_jsx(_components.code,{children:`blocked_reasons`}),`.`]}),`\n`,_jsx(Heading,{level:`3`,id:`get-agent-stats`,children:`Get Agent Stats`}),`\n`,_jsx(_components.p,{children:`Get statistics for a specific agent.`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`http`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`http`,children:_jsxs(_components.code,{language:`http`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`GET`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` /api/v1/agent/{agent_id}/stats`})]}),`\n`]})})}),`\n`,_jsx(_components.p,{children:_jsx(_components.strong,{children:`Response`})}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`8`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`8`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"agent_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"agent-123\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"total_tool_calls\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`1523`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"blocked_calls\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`12`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"avg_risk_score\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`0.15`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"active_sessions\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`0`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"anomalies_detected\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`2`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[_jsx(_components.code,{children:`active_sessions`}),` is `,_jsxs(_components.strong,{children:[`always `,_jsx(_components.code,{children:`0`})]}),` and is marked deprecated in the API schema. PromptGuard does not retain agent session state across requests, so there is nothing to count. The field is scheduled for removal in the next API version — do not build on it.`]})}),`\n`,_jsx(Heading,{level:`3`,id:`enforcement-is-opt-in-per-project`,children:`Enforcement is opt-in per project`}),`\n`,_jsxs(_components.p,{children:[`An agent’s policy — `,_jsx(_components.code,{children:`allowed_tools`}),`, `,_jsx(_components.code,{children:`blocked_tools`}),`, `,_jsx(_components.code,{children:`require_approval`}),` —\ndecides `,_jsx(_components.code,{children:`validate-tool`}),` verdicts only while the project’s\n`,_jsx(_components.strong,{children:_jsx(_components.code,{children:`agent_policy_enforced`})}),` setting is on. It is off by default: policies you\nwrite are shown on the dashboard’s Agent Security page and enforce nothing\nuntil you turn enforcement on there, or via the dashboard API:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`2`,language:`http`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`http`,children:_jsxs(_components.code,{language:`http`,numberOfLines:`2`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`PATCH`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` /dashboard/projects/{project_id}/settings`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{ `}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"agent_policy_enforced\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`true`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})]}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`The project response carries the current value. While enforcement is off,\nevery agent gets the platform-default tool lists. When it is on, an empty\n`,_jsx(_components.code,{children:`allowed_tools`}),` means `,_jsx(_components.strong,{children:`no allowlist is configured`}),` (the defaults stand), a\nnon-empty one replaces the default allowlist, and `,_jsx(_components.code,{children:`blocked_tools`}),` is added to\nthe platform defaults — a policy can narrow what an agent may do, never\nre-enable a dangerous default.`]}),`\n`,_jsx(Heading,{level:`3`,id:`end-agent-session-deprecated`,children:`End Agent Session (deprecated)`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`http`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`http`,children:_jsxs(_components.code,{language:`http`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`DELETE`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` /api/v1/agent/{agent_id}/session/{session_id}`})]}),`\n`]})})}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`This endpoint is a no-op.`}),` Server-side agent session state is not retained across requests, so there is no session to end. The route still returns `,_jsx(_components.code,{children:`200`}),` with the same keys as before plus `,_jsx(_components.code,{children:`\"deprecated\": true`}),`, and sends `,_jsx(_components.code,{children:`Deprecation: true`}),` and `,_jsx(_components.code,{children:`Sunset: Wed, 09 Dec 2026 00:00:00 GMT`}),`. It will be removed on or after that sunset date — stop calling it.`]})}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`6`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`6`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"status\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"session_ended\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"agent_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"agent-123\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"session_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"sess-456\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"deprecated\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`true`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`3`,id:`agent-security-health`,children:`Agent Security Health`}),`\n`,_jsx(_components.p,{children:`Health check for the agent security service. Useful for readiness probes before routing validation traffic.`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`http`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`http`,children:_jsxs(_components.code,{language:`http`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`GET`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` /api/v1/agent/health`})]}),`\n`]})})}),`\n`,_jsx(Heading,{level:`3`,id:`get-managed-policy`,children:`Get Managed Policy`}),`\n`,_jsx(_components.p,{children:`Get the org-managed update policy for an enrolled device (used by the desktop agent to apply fleet-managed update settings).`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`http`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`http`,children:_jsxs(_components.code,{language:`http`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`GET`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` /api/v1/agent/managed-policy`})]}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`This poll doubles as the device’s heartbeat: each call updates the device’s `,_jsx(_components.strong,{children:`Last seen`}),` in the fleet view. A device that shows `,_jsx(_components.code,{children:`never`}),` has enrolled but has not yet polled — check that the agent is installed and running on that machine.`]}),`\n`,_jsx(_components.p,{children:_jsx(_components.strong,{children:`Response`})}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`6`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`6`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"fleet\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`true`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"force_update_mode\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"auto\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"pinned_channel\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"stable\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"min_version_override\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`null`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`sdk-usage`,children:`SDK Usage`}),`\n`,_jsxs(Tabs,{children:[_jsx(Tab,{title:`Python`,id:`python`,children:_jsx(CodeBlock,{filename:``,numberOfLines:`18`,language:`python`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`python`,children:_jsxs(_components.code,{language:`python`,numberOfLines:`18`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`from`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` promptguard `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` PromptGuard`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`pg `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` PromptGuard() `}),_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# Uses PROMPTGUARD_API_KEY env var`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`tool_name, arguments `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"run_command\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, {`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"command\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"ls /tmp\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# Validate before executing a tool`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`result `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` pg.agent.validate_tool(`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:` agent_id`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"my-agent\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:` tool_name`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`tool_name,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:` arguments`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`arguments,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`if`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` result[`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"allowed\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`]:`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:` # Safe to execute`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` execute_tool(tool_name, arguments)`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`else`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`:`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:` print`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`f`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Blocked: `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`{`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`', '`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.join(result[`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'blocked_reasons'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`])`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`}`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`]})})})}),_jsx(Tab,{title:`Node.js`,id:`node-js`,children:_jsx(CodeBlock,{filename:``,numberOfLines:`18`,language:`javascript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`javascript`,children:_jsxs(_components.code,{language:`javascript`,numberOfLines:`18`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:`PromptGuard`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` } `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` require`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'promptguard-sdk'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`);`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` pg`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` new`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` PromptGuard`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(); `}),_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`// Uses PROMPTGUARD_API_KEY env var`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`async`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` function`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` guardedCall`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:`toolName`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:`args`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) {`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:` // Validate before executing a tool`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` result`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` pg`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`agent`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`validateTool`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'my-agent'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`toolName`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`args`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`);`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` if`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` (`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`result`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`allowed`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) {`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:` // Safe to execute`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` executeTool`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`toolName`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`args`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`);`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` } `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`else`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:` // The Node SDK returns camelCase fields: blockedReasons, riskScore, riskLevel`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` console`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`log`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:\"`Blocked: \"}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#569CD6`},children:\"${\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`result`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`blockedReasons`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`join`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`', '`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#D4D4D4`},children:`)`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#569CD6`},children:`}`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:\"`\"}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`);`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`guardedCall`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'run_command'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, { `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`command:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'ls /tmp'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` });`})]}),`\n`]})})})})]}),`\n`,_jsxs(_components.p,{children:[`Both print `,_jsx(_components.code,{children:`Blocked: Tool 'run_command' is blocked for security reasons`}),`. The Python SDK returns the response as a dict with the wire’s snake_case keys.`]}),`\n`,_jsx(Heading,{level:`2`,id:`risk-levels`,children:`Risk Levels`}),`\n`,_jsxs(_components.p,{children:[`The level follows from why the verdict was reached, not from `,_jsx(_components.code,{children:`risk_score`}),` ranges:`]}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Level`}),_jsx(_components.th,{children:`When`}),_jsx(_components.th,{children:_jsx(_components.code,{children:`allowed`})})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`safe`})}),_jsx(_components.td,{children:`The tool passed every check`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`true`})})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`low`})}),_jsx(_components.td,{children:`Allowed, with warnings about its arguments`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`true`})})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`medium`})}),_jsxs(_components.td,{children:[`The tool needs human review (`,_jsx(_components.code,{children:`write_file`}),`, `,_jsx(_components.code,{children:`create_file`}),`, `,_jsx(_components.code,{children:`modify_file`}),`, `,_jsx(_components.code,{children:`send_message`}),`, `,_jsx(_components.code,{children:`post`}),`, `,_jsx(_components.code,{children:`api_call`}),`, or arguments risky enough to need it)`]}),_jsx(_components.td,{children:_jsx(_components.code,{children:`false`})})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`high`})}),_jsx(_components.td,{children:`Dangerous or injection patterns in the arguments`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`false`})})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`critical`})}),_jsxs(_components.td,{children:[`The tool is on the blocked list (`,_jsx(_components.code,{children:`risk_score`}),` 1.0)`]}),_jsx(_components.td,{children:_jsx(_components.code,{children:`false`})})]})]})]}),`\n`,_jsx(Heading,{level:`2`,id:`blocked-tools-default`,children:`Blocked Tools (Default)`}),`\n`,_jsx(_components.p,{children:`These tools are blocked by default:`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[`Shell and command execution: `,_jsx(_components.code,{children:`execute_shell`}),`, `,_jsx(_components.code,{children:`run_command`}),`, `,_jsx(_components.code,{children:`shell`}),`, `,_jsx(_components.code,{children:`bash`}),`, `,_jsx(_components.code,{children:`exec`}),`, `,_jsx(_components.code,{children:`system`}),`, `,_jsx(_components.code,{children:`subprocess`}),`, `,_jsx(_components.code,{children:`os.system`})]}),`\n`,_jsxs(_components.li,{children:[`File deletion: `,_jsx(_components.code,{children:`delete_file`}),`, `,_jsx(_components.code,{children:`remove_file`}),`, `,_jsx(_components.code,{children:`rm`}),`, `,_jsx(_components.code,{children:`rmdir`}),`, `,_jsx(_components.code,{children:`unlink`})]}),`\n`,_jsxs(_components.li,{children:[`Process control: `,_jsx(_components.code,{children:`kill_process`}),`, `,_jsx(_components.code,{children:`terminate`})]}),`\n`,_jsxs(_components.li,{children:[`System changes: `,_jsx(_components.code,{children:`modify_system`}),`, `,_jsx(_components.code,{children:`change_permissions`}),`, `,_jsx(_components.code,{children:`chmod`}),`, `,_jsx(_components.code,{children:`chown`})]}),`\n`,_jsxs(_components.li,{children:[`Network sends: `,_jsx(_components.code,{children:`send_email`}),`, `,_jsx(_components.code,{children:`http_post`}),`, `,_jsx(_components.code,{children:`upload_file`})]}),`\n`]}),`\n`,_jsx(Heading,{level:`2`,id:`project-isolation`,children:`Project Isolation`}),`\n`,_jsx(_components.p,{children:`Agent profiles are isolated by project. This means:`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[`The same `,_jsx(_components.code,{children:`agent_id`}),` in different projects will have separate behavioral profiles`]}),`\n`,_jsx(_components.li,{children:`Profiles persist across restarts (stored in database)`}),`\n`,_jsx(_components.li,{children:`Each project maintains its own baseline for anomaly detection`}),`\n`]}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Developer API`}),`: `,_jsx(_components.code,{children:`project_id`}),` is automatically extracted from your API key. Ensure your API key is associated with a project.`]}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Consumer API`}),`: Include `,_jsx(_components.code,{children:`project_id`}),` in your request body. You must have access to the specified project.`]}),`\n`,_jsx(Heading,{level:`2`,id:`best-practices`,children:`Best Practices`}),`\n`,_jsxs(_components.ol,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Validate every tool call`}),`: Don’t skip validation for “safe” tools`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Use sessions`}),`: Group related calls for better behavior analysis`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Review anomalies`}),`: Investigate calls whose `,_jsx(_components.code,{children:`blocked_reasons`}),` include `,_jsx(_components.code,{children:`Anomaly detected`})]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Set up alerts`}),`: Monitor for patterns indicating compromise`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Use project-scoped API keys`}),`: Ensure your API keys are associated with projects for proper isolation`]}),`\n`]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"codeStyling":"system","config":{},"pageMetadata":{"title":"Agent Security API","description":"Agent Security API — validate tool calls and monitor agent behaviour.","href":"/api-reference/agent-security"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Agent Security API","slug":"agent-security-api","depth":1,"children":[]},{"title":"Why Agent Security?","slug":"why-agent-security","depth":2,"children":[]},{"title":"Endpoints","slug":"endpoints","depth":2,"children":[{"title":"Validate Tool Call","slug":"validate-tool-call","depth":3,"children":[]},{"title":"Get Agent Stats","slug":"get-agent-stats","depth":3,"children":[]},{"title":"Enforcement is opt-in per project","slug":"enforcement-is-opt-in-per-project","depth":3,"children":[]},{"title":"End Agent Session (deprecated)","slug":"end-agent-session-deprecated","depth":3,"children":[]},{"title":"Agent Security Health","slug":"agent-security-health","depth":3,"children":[]},{"title":"Get Managed Policy","slug":"get-managed-policy","depth":3,"children":[]}]},{"title":"SDK Usage","slug":"sdk-usage","depth":2,"children":[]},{"title":"Risk Levels","slug":"risk-levels","depth":2,"children":[]},{"title":"Blocked Tools (Default)","slug":"blocked-tools-default","depth":2,"children":[]},{"title":"Project Isolation","slug":"project-isolation","depth":2,"children":[]},{"title":"Best Practices","slug":"best-practices","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":[],"subdomain":"promptguard","siteName":"PromptGuard","title":"Agent Security API - PromptGuard","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-11-01T17:32:43.805Z","gitLastModified":"2026-11-01T13:27:47.000Z","originalFileLocation":"api-reference/agent-security.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Agent Security API — validate tool calls and monitor agent behaviour.\">\u003cmeta data-mint-head name=\"application-name\" content=\"PromptGuard\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/promptguard/qMghc8kofYAB8Q5A/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/promptguard/qMghc8kofYAB8Q5A/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/promptguard/qMghc8kofYAB8Q5A/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/promptguard/qMghc8kofYAB8Q5A/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/promptguard/qMghc8kofYAB8Q5A/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/promptguard/qMghc8kofYAB8Q5A/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/promptguard/qMghc8kofYAB8Q5A/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/promptguard/qMghc8kofYAB8Q5A/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/promptguard/qMghc8kofYAB8Q5A/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Agent Security API - PromptGuard\">\u003cmeta data-mint-head property=\"og:description\" content=\"Agent Security API — validate tool calls and monitor agent behaviour.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"PromptGuard Docs\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.promptguard.co/api-reference/agent-security\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://promptguard.mintlify.app/_mintlify/api/og/v2?division=Endpoints\u0026amp;title=Agent+Security+API\u0026amp;description=Agent+Security+API+%E2%80%94+validate+tool+calls+and+monitor+agent+behaviour.\u0026amp;theme=ce8c95952c632da2fc78e486\u0026amp;signature=9b689c482c832123a95620209077b9e55fc2b6438c91fb20c11e29bc424b0e16\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Agent Security API - PromptGuard\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Agent Security API — validate tool calls and monitor agent behaviour.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://promptguard.mintlify.app/_mintlify/api/og/v2?division=Endpoints\u0026amp;title=Agent+Security+API\u0026amp;description=Agent+Security+API+%E2%80%94+validate+tool+calls+and+monitor+agent+behaviour.\u0026amp;theme=ce8c95952c632da2fc78e486\u0026amp;signature=9b689c482c832123a95620209077b9e55fc2b6438c91fb20c11e29bc424b0e16\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/promptguard/qMghc8kofYAB8Q5A/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"PromptGuard\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#3B82F6\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.promptguard.co/api-reference/agent-security\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/api-reference/agent-security.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.promptguard.co/#organization\",\"name\":\"PromptGuard\",\"url\":\"https://docs.promptguard.co\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/promptguard/sBVZPqZYn263LC-L/logo/light.svg?fit=max\u0026auto=format\u0026n=sBVZPqZYn263LC-L\u0026q=85\u0026s=8bf0b3b1f4e6fcd571bd4fefce2cda92\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.promptguard.co#website\",\"name\":\"PromptGuard\",\"url\":\"https://docs.promptguard.co\",\"publisher\":{\"@id\":\"https://docs.promptguard.co/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.promptguard.co/api-reference/agent-security#webpage\",\"url\":\"https://docs.promptguard.co/api-reference/agent-security\",\"name\":\"Agent Security API\",\"description\":\"Agent Security API — validate tool calls and monitor agent behaviour.\",\"dateModified\":\"2026-11-01T13:27:47.000Z\",\"isPartOf\":{\"@id\":\"https://docs.promptguard.co#website\"},\"breadcrumb\":{\"@id\":\"https://docs.promptguard.co/api-reference/agent-security#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.promptguard.co/api-reference/agent-security#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Endpoints\",\"item\":\"https://docs.promptguard.co/api-reference/guard\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Agent Security API\",\"item\":\"https://docs.promptguard.co/api-reference/agent-security\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://docs.promptguard.co/api-reference/agent-security#article\",\"headline\":\"Agent Security API\",\"name\":\"Agent Security API\",\"description\":\"Agent Security API — validate tool calls and monitor agent behaviour.\",\"url\":\"https://docs.promptguard.co/api-reference/agent-security\",\"mainEntityOfPage\":{\"@id\":\"https://docs.promptguard.co/api-reference/agent-security#webpage\"},\"dateModified\":\"2026-11-01T13:27:47.000Z\",\"publisher\":{\"@id\":\"https://docs.promptguard.co/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.promptguard.co#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"PromptGuard\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"PromptGuard","nav":{"global":{"anchors":[{"anchor":"Dashboard","icon":"rectangle-terminal","href":"https://app.promptguard.co"},{"anchor":"Blog","icon":"newspaper","href":"https://promptguard.co/blog"}]},"tabs":[{"tab":"Documentation","icon":"book-open","pages":[{"title":"Documentation","href":""}]},{"tab":"API Reference","icon":"square-terminal","groups":[{"group":"Overview","icon":"rocket","pages":[{"title":"API Reference","href":"/api-reference/introduction"}]},{"group":"Endpoints","icon":"server","pages":[{"title":"Guard API","href":"/api-reference/guard"},{"title":"Security Scan, Redact \u0026 Test","description":"Standalone endpoints for threat scanning, PII redaction, and red-team testing of your own policy","href":"/api-reference/security-endpoints"},{"title":"Agent Security API","href":"/api-reference/agent-security"},{"title":"MCP Manifest Scan","description":"Scan an MCP server's tool list for poisoned descriptions, invisible characters and shadowed names, and pin it so a later change is flagged","href":"/api-reference/mcp-manifest-scan"},{"title":"API Keys Management","href":"/api-reference/api-keys"}]},{"group":"SDK Reference","icon":"code","pages":[{"title":"Python SDK reference","href":"/sdk-reference/python"},{"title":"Node.js SDK reference","href":"/sdk-reference/node"}]},{"group":"API Reference","pages":[{"title":"Proxy Chat Completions","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/chat/completions","href":"/api-reference/proxy-chat-completions"},{"title":"Proxy Messages","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/messages","href":"/api-reference/proxy-messages"},{"title":"Proxy Responses","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/responses","href":"/api-reference/proxy-responses"},{"title":"Proxy Count Tokens","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/messages/count_tokens","href":"/api-reference/proxy-count-tokens"},{"title":"Proxy Models","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/models","href":"/api-reference/proxy-models"},{"title":"Root","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /","href":"/api-reference/root"},{"title":"Health","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /health","href":"/api-reference/health"},{"title":"Version","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /version","href":"/api-reference/version"}]},{"group":"api-keys","pages":[{"title":"List Api Keys","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/api-keys","href":"/api-reference/api-keys/list-api-keys"},{"title":"Create Api Key","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/api-keys","href":"/api-reference/api-keys/create-api-key"},{"title":"Delete Api Key","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json delete /api/v1/api-keys/{key_id}","href":"/api-reference/api-keys/delete-api-key"},{"title":"Toggle Api Key","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json put /api/v1/api-keys/{key_id}/toggle","href":"/api-reference/api-keys/toggle-api-key"}]},{"group":"usage","pages":[{"title":"Get Usage Stats","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/usage/stats","href":"/api-reference/usage/get-usage-stats"}]},{"group":"projects","pages":[{"title":"List Projects","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/projects","href":"/api-reference/projects/list-projects"},{"title":"Create Project","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/projects","href":"/api-reference/projects/create-project"},{"title":"Get Project","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/projects/{project_id}","href":"/api-reference/projects/get-project"},{"title":"Delete Project","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json delete /api/v1/projects/{project_id}","href":"/api-reference/projects/delete-project"}]},{"group":"SIEM export","pages":[{"title":"Export Alerts","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/alerts","href":"/api-reference/siem-export/export-alerts"},{"title":"Export Interactions","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/interactions","href":"/api-reference/siem-export/export-interactions"},{"title":"Stream Interactions","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/interactions/stream","href":"/api-reference/siem-export/stream-interactions"},{"title":"Export Audit Events","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/audit-events","href":"/api-reference/siem-export/export-audit-events"},{"title":"Stream Audit Events","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/audit-events/stream","href":"/api-reference/siem-export/stream-audit-events"}]},{"group":"guardrails","pages":[{"title":"Get Project Guardrails","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/projects/{project_id}/guardrails","href":"/api-reference/guardrails/get-project-guardrails"},{"title":"Update Project Guardrails","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json put /api/v1/projects/{project_id}/guardrails","href":"/api-reference/guardrails/update-project-guardrails"}]},{"group":"fleet-device","pages":[{"title":"List Own Org Devices","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/fleet/devices","href":"/api-reference/fleet-device/list-own-org-devices"},{"title":"Describe Own Identity","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/fleet/identity","href":"/api-reference/fleet-device/describe-own-identity"},{"title":"Revoke Self","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json delete /api/v1/fleet/devices/self","href":"/api-reference/fleet-device/revoke-self"}]},{"group":"agent","pages":[{"title":"Validate Tool Call","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/agent/validate-tool","href":"/api-reference/agent/validate-tool-call"},{"title":"Ingest Agent Trace","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/agent/trace","href":"/api-reference/agent/ingest-agent-trace"},{"title":"Scan Agent Memory","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/agent/memory","href":"/api-reference/agent/scan-agent-memory"},{"title":"Get Agent Stats","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/agent/{agent_id}/stats","href":"/api-reference/agent/get-agent-stats"},{"title":"End Agent Session","deprecated":true,"version":null,"openapi":"/api-reference/openapi-developer.json delete /api/v1/agent/{agent_id}/session/{session_id}","href":"/api-reference/agent/end-agent-session"},{"title":"Agent Security Health","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/agent/health","href":"/api-reference/agent/agent-security-health"},{"title":"Managed Policy","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/agent/managed-policy","href":"/api-reference/agent/managed-policy"}]},{"group":"security","pages":[{"title":"Scan Content","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/security/scan","href":"/api-reference/security/scan-content"},{"title":"Redact Content","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/security/redact","href":"/api-reference/security/redact-content"}]},{"group":"mcp","pages":[{"title":"Scan Mcp Manifest","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/mcp/manifest-scan","href":"/api-reference/mcp/scan-mcp-manifest"}]},{"group":"security-testing","pages":[{"title":"Run All Tests","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/security-testing/run-all","href":"/api-reference/security-testing/run-all-tests"},{"title":"Run Custom Test","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/security-testing/run-custom","href":"/api-reference/security-testing/run-custom-test"},{"title":"List Tests Route","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/security-testing/tests","href":"/api-reference/security-testing/list-tests-route"},{"title":"Run Named Test","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/security-testing/run/{test_name}","href":"/api-reference/security-testing/run-named-test"}]},{"group":"guard","pages":[{"title":"Guard Content","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/guard","href":"/api-reference/guard/guard-content"}]},{"group":"enroll","pages":[{"title":"Enroll Device","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/enroll","href":"/api-reference/enroll/enroll-device"}]},{"group":"shadow-exceptions","pages":[{"title":"List Exceptions","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/exceptions","href":"/api-reference/shadow-exceptions/list-exceptions"},{"title":"Create Exception","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/exceptions","href":"/api-reference/shadow-exceptions/create-exception"},{"title":"List Active Grants","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/exceptions/active","href":"/api-reference/shadow-exceptions/list-active-grants"},{"title":"Get Exception","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/exceptions/{exception_id}","href":"/api-reference/shadow-exceptions/get-exception"},{"title":"Cancel Exception","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/exceptions/{exception_id}/cancel","href":"/api-reference/shadow-exceptions/cancel-exception"}]},{"group":"policies","pages":[{"title":"List Policies","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/policies","href":"/api-reference/policies/list-policies"}]},{"group":"overlays","pages":[{"title":"Preview Overlay","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/overlays/preview","href":"/api-reference/overlays/preview-overlay"},{"title":"Apply Overlay Endpoint","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/overlays/apply","href":"/api-reference/overlays/apply-overlay-endpoint"},{"title":"Get Active Overlay","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/overlays/active","href":"/api-reference/overlays/get-active-overlay"}]},{"group":"tool-requests","pages":[{"title":"List Tool Requests","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json get /api/v1/tool-requests","href":"/api-reference/tool-requests/list-tool-requests"},{"title":"Create Tool Request","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/tool-requests","href":"/api-reference/tool-requests/create-tool-request"},{"title":"Cancel Tool Request","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/tool-requests/{request_id}/cancel","href":"/api-reference/tool-requests/cancel-tool-request"}]},{"group":"GitHub Webhooks","pages":[{"title":"Handle Webhook","deprecated":null,"version":null,"openapi":"/api-reference/openapi-developer.json post /api/v1/github/webhook","href":"/api-reference/github-webhooks/handle-webhook"}]}]}]},"basePath":"","title":"Agent Security API - PromptGuard","buildId":"dpl_DeHjVRGfFnhYQwHnfC2pjeXXv8h9","deploymentId":"dpl_DeHjVRGfFnhYQwHnfC2pjeXXv8h9","dynamics":[],"chunks":[]}