Runtime Policy
Publish compiled policy that act runs, MCP, hooks, and cluster cells inherit at birth.
Runtime policy is the compiled execution contract for your workspace. Hosted act, cluster cells, MCP, hooks, and /api/mask all decide through the same published bundle. Act runs record compileHash at birth so audit and metrics prove which policy was live.
One bundle, every surface
You author protections and guard sets in the app. Publish merges them into a single workspace policy. There is no parallel MCP-only ruleset: IDE hooks, SDK calls, and cluster act paths read the same compile output.
Where it applies
Local, hosted, and cluster surfaces inherit the published compileHash.
Surfaces
- IDE hooksChat ingress and shell guard before tools run.
- MCP and ingressenforce-tool-call and mask on the control plane.
- Act runscreateCellRun stores compileHash on the run row.
- Cluster cellspolicy-bundle keeps sidecars aligned after publish.
Author and stage
Open Runtime policy to edit execution policy and guard sets. Use Review before you treat a change as production. Staging for MCP and SDK traffic is configured under Runtime enforcement (observe vs enforce on connectors).
Capability packs and workspace profiles in the app bind tools and scopes. They compile into the same publish flow; they are not a second policy language.
Publish
Publish from Runtime policy when reviewers approve. The publish card shows a new compileHash. Until you publish, new runs may still attach to the previous hash depending on staging settings.
Connected compute pulls updates through GET /api/compute/policy-bundle after heartbeat. See Spin up cells for cluster placement.
Verify compileHash
Confirm the live hash from the API or SDK, then open a run in Runs and match the row.
import { BleklineClient } from "@blekline/client";
const client = new BleklineClient({
baseUrl: process.env.BLEKLINE_API_URL ?? "https://app.blekline.com",
workspaceToken: process.env.BLEKLINE_WORKSPACE_TOKEN!,
metadata: { clientSurface: "sdk" },
});
const policy = await client.getExecutionPolicy();
console.log(policy.enforcementStage, policy.policy?.compileHash);curl -sS https://app.blekline.com/api/workspace/execution-policy \ -H "x-blekline-workspace-token: $BLEKLINE_WORKSPACE_TOKEN" | jq .compileHash,.enforcementStage
curl -sS -N https://app.blekline.com/api/workspace/policy-stream \ -H "x-blekline-workspace-token: $BLEKLINE_WORKSPACE_TOKEN" | head -n 1
Policy stream is useful for agents that need to react to publish events without polling execution-policy on every request. See Policy stream in the API reference.
Wire clients and act
After publish, connect IDE and SDK surfaces so enforce paths use the new hash. Follow Connect agents and clients. For production cells, publish before you raise act volume on connected clusters.
Threat signals and rule approvals refine policy over time without forking the spine. See Threat signals and approvals when you operate at scale.