<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: NieJingChuan</title>
    <description>The latest articles on DEV Community by NieJingChuan (@gangan).</description>
    <link>https://dev.to/gangan</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4030026%2F925b3683-1c92-4042-beee-763513fb6a5e.jpg</url>
      <title>DEV Community: NieJingChuan</title>
      <link>https://dev.to/gangan</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/gangan"/>
    <language>en</language>
    <item>
      <title>Approval Is Not a Boolean: What Must Still Be True When an Agent Resumes?</title>
      <dc:creator>NieJingChuan</dc:creator>
      <pubDate>Mon, 03 Aug 2026 03:14:05 +0000</pubDate>
      <link>https://dev.to/gangan/approval-is-not-a-boolean-what-must-still-be-true-when-an-agent-resumes-4ib2</link>
      <guid>https://dev.to/gangan/approval-is-not-a-boolean-what-must-still-be-true-when-an-agent-resumes-4ib2</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;Human approval is a decision about one action under a particular set of facts. It is not a permanent permission bit.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Imagine an AI agent preparing a refund request:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Order: SO-1001
Amount: CNY 199.00
Reason: Duplicate payment
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The runtime classifies the action as high risk, pauses the task, and asks a human to approve the exact request.&lt;/p&gt;

&lt;p&gt;At 10:00, the approver reviews the parameters and clicks &lt;strong&gt;Approve&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;The task does not execute immediately. It remains paused, waits in a queue, survives a coordinator restart, and finally reaches dispatch at 15:00.&lt;/p&gt;

&lt;p&gt;During those five hours, any of the following may have changed:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;the order may already have been refunded by another channel;&lt;/li&gt;
&lt;li&gt;the refund policy may now require an additional finance review;&lt;/li&gt;
&lt;li&gt;the approver may no longer hold the required role;&lt;/li&gt;
&lt;li&gt;the acting subject may have left the organization;&lt;/li&gt;
&lt;li&gt;the amount or currency may have drifted during task reconstruction;&lt;/li&gt;
&lt;li&gt;the tool implementation may have changed;&lt;/li&gt;
&lt;li&gt;the approval may have been valid for only 30 minutes.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Should the system execute merely because a database row still says &lt;code&gt;approved = true&lt;/code&gt;?&lt;/p&gt;

&lt;p&gt;No.&lt;/p&gt;

&lt;p&gt;The approval was not a timeless grant. It was a decision about a specific action, represented by a specific subject, using a specific capability, with specific arguments, under a specific policy and set of business facts.&lt;/p&gt;

&lt;p&gt;This distinction becomes essential when agents move beyond answering questions and begin creating real business consequences.&lt;/p&gt;

&lt;h2&gt;
  
  
  1. The dangerous simplification: &lt;code&gt;approval = true&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;In conventional administrative software, approval and execution are often close together. A user submits a form, a manager approves it, and the system performs the action soon afterward.&lt;/p&gt;

&lt;p&gt;That interaction encourages a simplified mental model:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;approval = true
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Once that value is stored, downstream code treats the action as permanently authorized.&lt;/p&gt;

&lt;p&gt;Agent tasks are different. A single task may cross several asynchronous boundaries:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;understand intent
  -&amp;gt; select a capability
  -&amp;gt; construct arguments
  -&amp;gt; request approval
  -&amp;gt; wait for a human
  -&amp;gt; resume the task
  -&amp;gt; enter a dispatch queue
  -&amp;gt; call the business system
  -&amp;gt; record the outcome
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The lifecycle may last minutes, hours, or days. Processes may restart. Policies may be redeployed. Business objects may change through other channels.&lt;/p&gt;

&lt;p&gt;In that environment, "approval happened" is only a historical fact. It does not prove that the action is still valid now.&lt;/p&gt;

&lt;p&gt;A production design must distinguish at least five concepts:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Concept&lt;/th&gt;
&lt;th&gt;Question it answers&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Approval intent&lt;/td&gt;
&lt;td&gt;Does this kind of operation require human intervention?&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Approval decision&lt;/td&gt;
&lt;td&gt;Did a qualified person agree to this specific action?&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Approval evidence&lt;/td&gt;
&lt;td&gt;What subject, capability, arguments, policy, and time did that decision bind?&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Approval validity&lt;/td&gt;
&lt;td&gt;Does that evidence still apply at dispatch time?&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Final business authority&lt;/td&gt;
&lt;td&gt;May the business system create this consequence now?&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Collapsing all five into one boolean hides the most important failure modes.&lt;/p&gt;

&lt;h2&gt;
  
  
  2. Approval must bind an action, not a vague intention
&lt;/h2&gt;

&lt;p&gt;An approval prompt such as this is not enough:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Approve the refund?
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It does not tell the approver:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;which order will be changed;&lt;/li&gt;
&lt;li&gt;how much money will move;&lt;/li&gt;
&lt;li&gt;which currency is involved;&lt;/li&gt;
&lt;li&gt;whose authority the agent represents;&lt;/li&gt;
&lt;li&gt;which capability will execute;&lt;/li&gt;
&lt;li&gt;which policy version produced the approval requirement;&lt;/li&gt;
&lt;li&gt;how long the decision remains valid;&lt;/li&gt;
&lt;li&gt;whether the task may execute more than once.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;A useful approval record should bind a concrete execution envelope. Depending on the assurance level, it may include:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;trusted_subject
capability
canonical_arguments
task_identity
policy_version
approval_time
expiry_time
approver
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Higher-assurance deployments may also bind:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;tenant
business_object_version
tool_or_server_artifact
request_purpose
delegation_context
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Not every implementation needs the same representation. Some may use a signed object, some a durable database record, and some an external approval system. The invariant is more important than the format:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;The system must be able to prove that what is about to execute is still the action that was reviewed.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  3. A parameter hash protects structure, not time
&lt;/h2&gt;

&lt;p&gt;A common safeguard is to canonicalize the arguments and store a hash:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;args_hash = SHA256(canonical_json(arguments))
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Before dispatch, the runtime computes the hash again. If the value differs, the previous approval cannot be reused.&lt;/p&gt;

&lt;p&gt;This prevents a dangerous class of drift:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;At approval:
  order_id = SO-1001
  amount = 199.00

At execution:
  order_id = SO-1001
  amount = 19900.00
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;But an identical parameter hash does not prove that execution is still safe.&lt;/p&gt;

&lt;p&gt;The arguments may be unchanged while:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;the acting subject has lost access;&lt;/li&gt;
&lt;li&gt;the approval has expired;&lt;/li&gt;
&lt;li&gt;the applicable policy has changed;&lt;/li&gt;
&lt;li&gt;the order has already been refunded;&lt;/li&gt;
&lt;li&gt;the capability now points to a different implementation.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;So argument equality is a necessary condition for approval reuse, not a sufficient one.&lt;/p&gt;

&lt;p&gt;This is the core distinction:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Structural integrity:
  Is this the same request?

Temporal validity:
  Is the decision still applicable now?
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;A robust system needs both.&lt;/p&gt;

&lt;h2&gt;
  
  
  4. Four kinds of drift can invalidate an approval
&lt;/h2&gt;

&lt;p&gt;Approval freshness is not one check. It is a collection of checks owned by different components.&lt;/p&gt;

&lt;h3&gt;
  
  
  4.1 Request drift
&lt;/h3&gt;

&lt;p&gt;The capability, canonical arguments, trusted subject, tenant, or task identity no longer matches the approved envelope.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Expected behavior:&lt;/strong&gt; do not dispatch. Return the same durable task to an approval-required state or reject it before dispatch.&lt;/p&gt;

&lt;h3&gt;
  
  
  4.2 Subject and authority drift
&lt;/h3&gt;

&lt;p&gt;The acting subject or approver no longer holds the role, membership, delegation, or authority required by current policy.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Expected behavior:&lt;/strong&gt; re-resolve trusted identity and authorization from an authoritative system. Never trust model-generated identity fields.&lt;/p&gt;

&lt;h3&gt;
  
  
  4.3 Policy and capability drift
&lt;/h3&gt;

&lt;p&gt;The risk policy, approval threshold, route allowlist, capability declaration, or tool implementation changed while the task was paused.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Expected behavior:&lt;/strong&gt; compare the approved policy and capability context with the current context. If the change is material, require a new decision.&lt;/p&gt;

&lt;h3&gt;
  
  
  4.4 Business object drift
&lt;/h3&gt;

&lt;p&gt;The order, invoice, account, inventory item, deployment target, or other business object changed after approval.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Expected behavior:&lt;/strong&gt; the business system, or a fresh preflight API backed by the same authoritative data, must re-evaluate current state and final permission.&lt;/p&gt;

&lt;p&gt;The ownership boundary can be summarized as follows:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;What may have changed?&lt;/th&gt;
&lt;th&gt;Natural owner of the current truth&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Canonical arguments and task identity&lt;/td&gt;
&lt;td&gt;Agent runtime or shared execution control&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Trusted subject and delegation&lt;/td&gt;
&lt;td&gt;Identity and authorization systems&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Approval validity and policy version&lt;/td&gt;
&lt;td&gt;Approval authority and deployment policy&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Capability route or tool artifact&lt;/td&gt;
&lt;td&gt;Execution control and tool operator&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Business object state and final permission&lt;/td&gt;
&lt;td&gt;Business system&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;No single approval service can safely manufacture all of these truths.&lt;/p&gt;

&lt;h2&gt;
  
  
  5. Dispatch is the real checkpoint
&lt;/h2&gt;

&lt;p&gt;The most important validation moment is not when the human clicks &lt;strong&gt;Approve&lt;/strong&gt;. It is immediately before the business action is dispatched.&lt;/p&gt;

&lt;p&gt;A conservative resume path looks like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;1. Load the same durable task identity.
2. Reconstruct the canonical execution envelope.
3. Verify that the capability and arguments still match the approval evidence.
4. Check whether the approval is expired or revoked.
5. Compare the approved policy context with the current policy context.
6. Re-resolve the trusted subject where required.
7. Dispatch with a stable business idempotency identity.
8. Let the business system recheck object state and final authority.
9. Record the outcome against the same task.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If any pre-dispatch binding fails, the task must not silently continue.&lt;/p&gt;

&lt;p&gt;The correct outcome is usually one of:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;awaiting_reapproval
rejected_pre_dispatch
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The exact state name is implementation-specific. The safety property is not:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;"We have an approval record."&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;It is:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;"No business dispatch occurs under approval evidence that is no longer valid."&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  6. Expiry is not a retryable transport failure
&lt;/h2&gt;

&lt;p&gt;Approval expiry must not be handled like a temporary network error.&lt;/p&gt;

&lt;p&gt;Consider this sequence:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;task T is approved
  -&amp;gt; approval expires
  -&amp;gt; dispatcher attempts to resume T
  -&amp;gt; validation detects expiry
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Unsafe implementations may create a new task, retry automatically, or reuse the old approval because the arguments have not changed.&lt;/p&gt;

&lt;p&gt;All three behaviors weaken the control boundary.&lt;/p&gt;

&lt;p&gt;The safer rule is:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;same durable task
  -&amp;gt; expired approval detected
  -&amp;gt; no dispatch
  -&amp;gt; explicit reapproval or terminal rejection
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Creating a new task merely to bypass an expired decision destroys continuity. Treating expiry as a transport retry confuses policy failure with delivery failure. Reusing the old decision converts a time-bounded approval into permanent authority.&lt;/p&gt;

&lt;p&gt;The task identity should survive. The authorization to execute may not.&lt;/p&gt;

&lt;h2&gt;
  
  
  7. Policy version is part of the approval context
&lt;/h2&gt;

&lt;p&gt;An approval decision is usually produced under some policy version:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;policy_version = refund-policy-2026-08-01
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;When the task resumes, the runtime should be able to compare:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;approved_policy_version
current_policy_version
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;But a version mismatch does not always require the same response.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Policy change&lt;/th&gt;
&lt;th&gt;Example&lt;/th&gt;
&lt;th&gt;Possible response&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Non-material&lt;/td&gt;
&lt;td&gt;Wording or UI guidance changed&lt;/td&gt;
&lt;td&gt;Continue while preserving evidence&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;More restrictive&lt;/td&gt;
&lt;td&gt;Finance approval is now required&lt;/td&gt;
&lt;td&gt;Require reapproval&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Less restrictive&lt;/td&gt;
&lt;td&gt;The no-approval threshold increased&lt;/td&gt;
&lt;td&gt;Reuse or re-evaluate according to deployment policy&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;A portable contract can require implementations to preserve the relevant policy context. It should not attempt to standardize every enterprise's definition of a material policy change.&lt;/p&gt;

&lt;p&gt;That decision belongs to deployment policy and the authority that owns the rule.&lt;/p&gt;

&lt;h2&gt;
  
  
  8. Approval freshness does not replace business freshness
&lt;/h2&gt;

&lt;p&gt;Even perfectly valid approval evidence cannot prove that an order is still refundable.&lt;/p&gt;

&lt;p&gt;The approval layer may know:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;the approver agreed to refund SO-1001 for CNY 199.00
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Only the business domain can reliably know:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;whether SO-1001 still exists
whether it belongs to the current tenant
whether CNY 199.00 remains refundable
whether another refund already succeeded
whether the subject may perform this action now
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is why an agent governance architecture must preserve the final business boundary.&lt;/p&gt;

&lt;p&gt;Approval is evidence that a required human decision occurred. It is not a substitute for current object-level authorization, transaction constraints, tenant isolation, or domain invariants.&lt;/p&gt;

&lt;p&gt;In short:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Approval controls whether execution may proceed.
The business system controls whether the consequence may exist.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  9. Make the boundary executable
&lt;/h2&gt;

&lt;p&gt;Architecture diagrams are not enough. Approval validity should be expressed as failure scenarios that different implementations can run.&lt;/p&gt;

&lt;p&gt;One useful test case is:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Scenario: approval expires while a task is paused

Given:
  - one durable task identity
  - approval evidence bound to a trusted subject,
    canonical arguments, capability, and policy version
  - implementation-defined validity metadata

When:
  - the runtime attempts to resume or dispatch the task
  - after the approval is no longer valid

Then:
  - expiry is detected before dispatch
  - dispatch_count remains 0
  - business_effect_count remains 0
  - the old approval is not reused
  - the same task moves to reapproval or pre-dispatch rejection
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The test should also forbid these shortcuts:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;dispatching under expired approval;&lt;/li&gt;
&lt;li&gt;treating expiry as a retryable transport error;&lt;/li&gt;
&lt;li&gt;creating a new durable task to evade expiry;&lt;/li&gt;
&lt;li&gt;interpreting prior approval as current business authority.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Implementations may choose different clocks, leases, TTL formats, state names, and workflow engines. They should still be able to prove the same externally observable property.&lt;/p&gt;

&lt;p&gt;That is the difference between saying "we support human approval" and demonstrating that approval remains meaningful under failure and delay.&lt;/p&gt;

&lt;h2&gt;
  
  
  10. What belongs in a portable contract, and what does not?
&lt;/h2&gt;

&lt;p&gt;It is tempting to solve this by adding every runtime concern to a capability declaration:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt;&lt;span class="na"&gt;approval&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
  &lt;span class="na"&gt;required&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;
  &lt;span class="na"&gt;ttl&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;30m&lt;/span&gt;
  &lt;span class="na"&gt;workflow&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;finance-review-v7&lt;/span&gt;
  &lt;span class="na"&gt;approver_query&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;...&lt;/span&gt;
  &lt;span class="na"&gt;policy_engine&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;...&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That quickly turns a portable declaration into an organization-specific workflow language.&lt;/p&gt;

&lt;p&gt;A cleaner boundary is:&lt;/p&gt;

&lt;h3&gt;
  
  
  Portable capability declaration
&lt;/h3&gt;

&lt;p&gt;It can express that an operation carries approval intent and other stable governance semantics.&lt;/p&gt;

&lt;h3&gt;
  
  
  Runtime and approval authority
&lt;/h3&gt;

&lt;p&gt;They implement evidence binding, validity metadata, expiry, revocation, pause and resume behavior, and policy-version handling.&lt;/p&gt;

&lt;h3&gt;
  
  
  Business system
&lt;/h3&gt;

&lt;p&gt;It rechecks current subject authority, tenant boundaries, object state, domain invariants, and final permission immediately before creating the consequence.&lt;/p&gt;

&lt;p&gt;The standard should describe the smallest portable meaning. Implementations should make the operational guarantee real. The business system should retain authority over its own state.&lt;/p&gt;

&lt;p&gt;This division is deliberate. It keeps the contract interoperable without pretending that one schema can replace enterprise identity, approval workflows, or business authorization.&lt;/p&gt;

&lt;h2&gt;
  
  
  11. A practical review checklist
&lt;/h2&gt;

&lt;p&gt;When reviewing an agent approval path, ask:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Is approval bound to the exact capability and canonical arguments?&lt;/li&gt;
&lt;li&gt;Is the trusted subject sourced outside model-generated input?&lt;/li&gt;
&lt;li&gt;Does the approval carry validity or revocation semantics?&lt;/li&gt;
&lt;li&gt;Is the applicable policy version preserved?&lt;/li&gt;
&lt;li&gt;Are material policy changes detected before dispatch?&lt;/li&gt;
&lt;li&gt;Does task resume preserve one durable task identity?&lt;/li&gt;
&lt;li&gt;Does expired approval return to reapproval instead of automatic retry?&lt;/li&gt;
&lt;li&gt;Is a stable idempotency identity carried to the business boundary?&lt;/li&gt;
&lt;li&gt;Does the business system recheck current object state and final authority?&lt;/li&gt;
&lt;li&gt;Can tests prove that invalid approval produces zero business effects?&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;If the system cannot answer these questions, &lt;code&gt;approved = true&lt;/code&gt; is not a governance guarantee. It is only a historical flag.&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;Human-in-the-loop is often presented as a screen with two buttons: &lt;strong&gt;Approve&lt;/strong&gt; and &lt;strong&gt;Reject&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;The real engineering problem begins after the click.&lt;/p&gt;

&lt;p&gt;An approval decision must remain bound to the subject, capability, arguments, task, policy, and validity conditions that gave it meaning. When a paused agent task resumes, the system must determine whether those bindings still hold. If they do not, execution must stop before dispatch. If they do, the business system must still perform fresh, final authorization.&lt;/p&gt;

&lt;p&gt;The governing principle is simple:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Approval is not a boolean. It is time-bound evidence for one concrete action, and its validity must be proven again at the moment of execution.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  Further Reading
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://www.bailinghub.com/en/guides/mcp-safe-execution" rel="noopener noreferrer"&gt;What Is Missing Between MCP Tool Selection and Safe Execution?&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://agentcapability.org/" rel="noopener noreferrer"&gt;Agent Capability Contract (ACC)&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/bailinghub/bailinghub" rel="noopener noreferrer"&gt;BailingHub on GitHub&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Disclosure
&lt;/h2&gt;

&lt;p&gt;I maintain ACC and BailingHub, two open-source efforts exploring portable capability-governance semantics and self-hosted execution controls for agents operating existing business systems. They are concrete design experiments, not the only valid architecture. The business system remains the final authority.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>security</category>
      <category>architecture</category>
      <category>agents</category>
    </item>
    <item>
      <title>What Is Missing Between MCP Tool Selection and Safe Execution?</title>
      <dc:creator>NieJingChuan</dc:creator>
      <pubDate>Mon, 27 Jul 2026 09:28:00 +0000</pubDate>
      <link>https://dev.to/gangan/what-is-missing-between-mcp-tool-selection-and-safe-execution-432a</link>
      <guid>https://dev.to/gangan/what-is-missing-between-mcp-tool-selection-and-safe-execution-432a</guid>
      <description>&lt;p&gt;An agent discovers an MCP tool, produces arguments that match its schema, and sends a valid &lt;code&gt;tools/call&lt;/code&gt; request.&lt;/p&gt;

&lt;p&gt;Has the business action now been executed safely?&lt;/p&gt;

&lt;p&gt;For a read-only demo, that distinction may not matter much. It matters immediately when the tool can create a refund, change inventory, disable an account, send a customer notification, or trigger a deployment.&lt;/p&gt;

&lt;p&gt;In those cases, a valid tool call is only one event in a longer business-action lifecycle.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Short answer:&lt;/strong&gt; MCP can standardize tool discovery and invocation. Safe business execution remains an end-to-end property shared across the MCP server, agent runtime, execution controls, enterprise policy systems, and the authoritative business system.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The missing work usually includes:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;resolving the trusted acting subject;&lt;/li&gt;
&lt;li&gt;limiting which capabilities the agent may reach;&lt;/li&gt;
&lt;li&gt;deciding whether human approval is required;&lt;/li&gt;
&lt;li&gt;binding that approval to the exact request;&lt;/li&gt;
&lt;li&gt;preventing duplicate effects;&lt;/li&gt;
&lt;li&gt;handling retries and unknown outcomes;&lt;/li&gt;
&lt;li&gt;producing verifiable audit evidence;&lt;/li&gt;
&lt;li&gt;recovering from partial failure;&lt;/li&gt;
&lt;li&gt;performing final object-level and business-state authorization.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The difficult question is not whether these controls are useful. It is &lt;strong&gt;where each responsibility belongs&lt;/strong&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  A valid &lt;code&gt;tools/call&lt;/code&gt; is not business completion
&lt;/h2&gt;

&lt;p&gt;MCP already provides substantial foundations. A server can expose tool names, descriptions, input and output schemas, annotations, and execution-related metadata. A client can discover those tools and invoke them through a common protocol.&lt;/p&gt;

&lt;p&gt;MCP also specifies authorization for HTTP transports and publishes security guidance around access control, token handling, scope minimization, session binding, sandboxing, timeouts, confirmation, and audit logging.&lt;/p&gt;

&lt;p&gt;So this is not an argument that MCP "forgot security."&lt;/p&gt;

&lt;p&gt;It is a distinction between two different outcomes:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Protocol success:
  A valid request reached an authorized MCP server.

Business completion:
  The intended action was executed once, for the right subject,
  against the right object, under current business rules,
  with the required approval, evidence, and recovery behavior.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;A protocol can carry an action. It cannot independently know whether order &lt;code&gt;ORD-9001&lt;/code&gt; is still refundable, whether employee &lt;code&gt;E-1024&lt;/code&gt; may act for store &lt;code&gt;S-18&lt;/code&gt;, whether the requested amount exceeds the remaining refundable balance, or whether another refund has already completed.&lt;/p&gt;

&lt;p&gt;Those facts live closer to the business domain and change over time.&lt;/p&gt;

&lt;h2&gt;
  
  
  Five responsibilities, even when they share one process
&lt;/h2&gt;

&lt;p&gt;Production architectures become easier to reason about when we separate five responsibilities.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Layer&lt;/th&gt;
&lt;th&gt;Primary responsibility&lt;/th&gt;
&lt;th&gt;It must not be mistaken for&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Tool protocol and MCP server&lt;/td&gt;
&lt;td&gt;Tool discovery, schemas, invocation, protocol authorization, and the tool execution interface&lt;/td&gt;
&lt;td&gt;Final authorization for every downstream business object&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Agent runtime or orchestrator&lt;/td&gt;
&lt;td&gt;Interpret the task, select tools, generate arguments, maintain workflow state, and present human interaction&lt;/td&gt;
&lt;td&gt;A trusted source of business identity or final permission&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Shared execution control&lt;/td&gt;
&lt;td&gt;Restrict reachable capabilities, validate trusted context, bind approvals, coordinate dispatch, deduplicate requests, and retain traceable task state&lt;/td&gt;
&lt;td&gt;The enterprise identity provider, approval authority, transaction coordinator, or business policy owner&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Enterprise identity, policy, and approval systems&lt;/td&gt;
&lt;td&gt;Resolve trusted identities, organization-specific policy, and who may approve which action&lt;/td&gt;
&lt;td&gt;The business operation itself&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Business system&lt;/td&gt;
&lt;td&gt;Enforce tenant boundaries, object-level authorization, current state, business invariants, transactions, and the final decision to execute&lt;/td&gt;
&lt;td&gt;A passive backend that trusts upstream claims blindly&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;These rows do not require five deployments. One service may implement several of them.&lt;/p&gt;

&lt;p&gt;The separation is semantic. Security claims should follow responsibility, not topology.&lt;/p&gt;

&lt;h2&gt;
  
  
  "Permission" is really three decisions
&lt;/h2&gt;

&lt;p&gt;Architecture discussions often use &lt;em&gt;permission&lt;/em&gt; as though it were one check. In an agent-to-business path, it usually hides at least three.&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Can the client access this MCP server?
&lt;/h3&gt;

&lt;p&gt;This is protocol authorization: OAuth scopes, audience validation, token expiry, and protected-resource metadata.&lt;/p&gt;

&lt;h3&gt;
  
  
  2. Should this capability be reachable in this agent scenario?
&lt;/h3&gt;

&lt;p&gt;A customer-support agent may need &lt;code&gt;order.read&lt;/code&gt; and &lt;code&gt;refund.request.create&lt;/code&gt; without ever seeing &lt;code&gt;employee.delete&lt;/code&gt; or &lt;code&gt;tenant.config.update&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;This is a &lt;strong&gt;reach&lt;/strong&gt; decision. It reduces the maximum capability surface before model selection and argument generation can cause harm.&lt;/p&gt;

&lt;h3&gt;
  
  
  3. Can this subject perform this exact action on this object now?
&lt;/h3&gt;

&lt;p&gt;This is final business authority:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Does the employee belong to the relevant tenant or store?&lt;/li&gt;
&lt;li&gt;Is the order currently refundable?&lt;/li&gt;
&lt;li&gt;Is the amount within the remaining refundable balance?&lt;/li&gt;
&lt;li&gt;Has another refund already completed?&lt;/li&gt;
&lt;li&gt;Does current organization policy permit the action?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Only the business system, or an authority with equivalent fresh business context, can answer these questions reliably.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;MCP authorization
  -&amp;gt; Can this client access the server?

Capability reach
  -&amp;gt; Can this agent scenario reach this operation?

Business authority
  -&amp;gt; Can this subject perform this exact action now?
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;A valid MCP token is not an order-level refund decision. A capability allowlist is not tenant isolation. A successful business permission check does not remove the value of minimizing which tools the model can reach.&lt;/p&gt;

&lt;h2&gt;
  
  
  Where do the cross-cutting controls belong?
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Human approval
&lt;/h3&gt;

&lt;p&gt;The agent runtime may be the best place to present an approval screen. A shared execution layer can pause dispatch and bind the decision to a canonical request. An enterprise approval system decides who is qualified to approve. The business system still performs final authorization immediately before changing state.&lt;/p&gt;

&lt;p&gt;A useful approval binding includes at least:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;trusted subject + capability + canonical arguments + task identity
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If any of those values change, the previous approval must not silently authorize the new request.&lt;/p&gt;

&lt;p&gt;Approval UI is therefore not the approval boundary by itself. The evidence must be bound to what will execute, and the verifier must know which authority produced it.&lt;/p&gt;

&lt;h3&gt;
  
  
  Idempotency and duplicate prevention
&lt;/h3&gt;

&lt;p&gt;The runtime should preserve a stable request identity across retries. A shared execution layer can deduplicate submissions and retain task state. The business system must enforce domain-level uniqueness where duplicate effects would be harmful.&lt;/p&gt;

&lt;p&gt;For a refund, an execution layer can prevent one task from being dispatched twice. Only the payment or order domain can guarantee that the same business refund is not created through another path.&lt;/p&gt;

&lt;h3&gt;
  
  
  Retries and unknown outcomes
&lt;/h3&gt;

&lt;p&gt;Blind HTTP retry is unsafe for writes because a missing response does not prove that the action did not happen.&lt;/p&gt;

&lt;p&gt;A stateful task protocol should distinguish states such as:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;accepted -&amp;gt; awaiting_approval -&amp;gt; queued -&amp;gt; running -&amp;gt; succeeded
                                      \-&amp;gt; rejected
                                      \-&amp;gt; failed
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;After a timeout, the caller should query or resume the same task identity instead of inventing a new business request. Retry policy belongs near execution coordination, but retry safety depends on idempotency all the way to the business boundary.&lt;/p&gt;

&lt;h3&gt;
  
  
  Audit and evidence
&lt;/h3&gt;

&lt;p&gt;Application logs answer operational questions. An audit trail answers accountability questions:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Who requested the action?&lt;/li&gt;
&lt;li&gt;Which trusted subject did the agent represent?&lt;/li&gt;
&lt;li&gt;Which capability and arguments were evaluated?&lt;/li&gt;
&lt;li&gt;Which policy or approval decision affected execution?&lt;/li&gt;
&lt;li&gt;What was dispatched, by whom, and when?&lt;/li&gt;
&lt;li&gt;What did the business system finally accept or reject?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If one compromised runtime can both claim that approval happened and author the only audit record, the record is a self-report. Higher-assurance deployments may need independently signed approval evidence, append-only storage, or verification at the business boundary.&lt;/p&gt;

&lt;p&gt;A shared control layer can make evidence consistent. Calling its own log an "audit trail" does not make every assertion independently trustworthy.&lt;/p&gt;

&lt;h3&gt;
  
  
  Rollback and recovery
&lt;/h3&gt;

&lt;p&gt;Rollback is not a generic middleware feature.&lt;/p&gt;

&lt;p&gt;Some actions are reversible. Some require compensating operations. Some cannot be undone. Recovery semantics belong to the business operation or to a workflow/Saga layer that understands the domain.&lt;/p&gt;

&lt;p&gt;An execution layer can retain state, expose failure, and trigger an explicitly defined compensation path. It must not manufacture atomicity by labeling unrelated tool calls "atomic."&lt;/p&gt;

&lt;h2&gt;
  
  
  A minimal refund path
&lt;/h2&gt;

&lt;p&gt;Consider an agent asked to refund an order:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;1. A user requests a refund.
2. The agent runtime selects refund.create and proposes arguments.
3. The MCP client invokes the trusted server using protocol authorization.
4. Execution control verifies that refund.create is reachable for this route.
5. Trusted subject context is resolved outside model-generated arguments.
6. Request schema and governance conditions are evaluated.
7. If approval is required, execution pauses on an exact parameter snapshot.
8. The same task resumes with verifiable approval evidence.
9. Dispatch uses a stable idempotency identity.
10. The business system rechecks subject, tenant, order state, amount, and invariants.
11. The business system commits or rejects the action.
12. The result and evidence chain are recorded against the same task.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;There is no single "agent security check" in this sequence.&lt;/p&gt;

&lt;p&gt;The model proposes an action. The protocol carries it. The runtime coordinates it. Enterprise systems establish identity and policy. The business system authorizes and commits the final consequence.&lt;/p&gt;

&lt;h2&gt;
  
  
  Do you need a shared execution layer?
&lt;/h2&gt;

&lt;p&gt;Not always.&lt;/p&gt;

&lt;p&gt;A single-user local tool, a read-only utility, or an application with one runtime and a few low-consequence operations may keep these controls inside its MCP server or host application.&lt;/p&gt;

&lt;p&gt;A shared execution boundary becomes more useful when:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;multiple agent frameworks or MCP clients call the same business systems;&lt;/li&gt;
&lt;li&gt;many MCP servers repeat approval, idempotency, and audit logic;&lt;/li&gt;
&lt;li&gt;the organization needs one capability allowlist across channels;&lt;/li&gt;
&lt;li&gt;work must pause and resume across human approval or local executors;&lt;/li&gt;
&lt;li&gt;execution state must survive process restarts;&lt;/li&gt;
&lt;li&gt;governance evidence must be comparable across tools;&lt;/li&gt;
&lt;li&gt;business credentials should not be distributed to every agent application.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The architectural test is not "Are we using agents?"&lt;/p&gt;

&lt;p&gt;It is:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Are the same execution guarantees being reimplemented in enough places that a shared control boundary would reduce inconsistency and blast radius?&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Even then, the shared layer should remain deliberately limited. It coordinates and enforces common controls. It does not become the source of every identity, policy, transaction, or business truth.&lt;/p&gt;

&lt;h2&gt;
  
  
  Make failures explicit
&lt;/h2&gt;

&lt;p&gt;The following table is more useful than a general claim that a platform "supports governance."&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Failure&lt;/th&gt;
&lt;th&gt;Conservative behavior&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Trusted subject is missing or unverifiable&lt;/td&gt;
&lt;td&gt;Do not dispatch a subject-required action&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Tool metadata or governance declaration is untrusted&lt;/td&gt;
&lt;td&gt;Do not elevate privileges based on it&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Approval evidence does not match the exact request&lt;/td&gt;
&lt;td&gt;Reject it or require new approval&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Execution state is unknown after timeout&lt;/td&gt;
&lt;td&gt;Query the same task; do not create a fresh write blindly&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Idempotency identity is missing for a retryable write&lt;/td&gt;
&lt;td&gt;Refuse automatic retry&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Business authorization fails&lt;/td&gt;
&lt;td&gt;Return a final rejection; upstream approval does not override it&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Audit sink is unavailable&lt;/td&gt;
&lt;td&gt;Follow an explicit fail-open or fail-closed policy; never pretend evidence was persisted&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Compensation is undefined&lt;/td&gt;
&lt;td&gt;Report an irreversible or manual-recovery state; do not claim rollback support&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;These behaviors make the architecture testable.&lt;/p&gt;

&lt;h2&gt;
  
  
  Disclosure: where ACC and BailingHub fit
&lt;/h2&gt;

&lt;p&gt;I maintain two open-source efforts that explore parts of this problem.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://agentcapability.org/" rel="noopener noreferrer"&gt;Agent Capability Contract (ACC)&lt;/a&gt; experiments with a portable, operation-level declaration of capability reach and governance intent. It does not execute tools, define enterprise identity, or replace final business authorization.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/bailinghub/bailinghub" rel="noopener noreferrer"&gt;BailingHub&lt;/a&gt; experiments with a self-hosted execution control plane for reach restrictions, trusted-subject handling, approval binding, task state, dispatch, and traceability around business tool calls.&lt;/p&gt;

&lt;p&gt;They are concrete design experiments, not the only answer. The broader responsibility map does not depend on either project. The same boundaries can be implemented inside an MCP server, an agent platform, an API gateway, a workflow engine, a shared control plane, or a combination of them.&lt;/p&gt;

&lt;p&gt;What matters is whether the architecture can answer:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Which component controls tool reach?&lt;/li&gt;
&lt;li&gt;Where does trusted subject identity come from?&lt;/li&gt;
&lt;li&gt;Who decides that approval is required, and who is qualified to approve?&lt;/li&gt;
&lt;li&gt;What exact request did the approval authorize?&lt;/li&gt;
&lt;li&gt;How are retries tied to stable idempotency?&lt;/li&gt;
&lt;li&gt;Which component records evidence, and who can independently verify it?&lt;/li&gt;
&lt;li&gt;Which system performs final object-level and business-state authorization?&lt;/li&gt;
&lt;li&gt;What happens when execution is partial, unknown, rejected, or irreversible?&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;MCP makes tool interoperability practical. Safe business execution is the end-to-end property that must be constructed around the call.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Where do approval binding, idempotency state, and audit evidence live in your MCP stack today, and which component can independently verify them?&lt;/strong&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  References
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://modelcontextprotocol.io/specification/2025-11-25/server/tools" rel="noopener noreferrer"&gt;MCP Tools specification&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://modelcontextprotocol.io/specification/2025-11-25/basic/authorization" rel="noopener noreferrer"&gt;MCP Authorization specification&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://modelcontextprotocol.io/docs/tutorials/security/security_best_practices" rel="noopener noreferrer"&gt;MCP Security Best Practices&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://modelcontextprotocol.io/specification/2025-11-25/basic/utilities/tasks" rel="noopener noreferrer"&gt;MCP Tasks utility&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://blog.modelcontextprotocol.io/posts/2026-03-16-tool-annotations/" rel="noopener noreferrer"&gt;Tool Annotations as Risk Vocabulary: What Hints Can and Can't Do&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>mcp</category>
      <category>ai</category>
      <category>security</category>
      <category>architecture</category>
    </item>
    <item>
      <title>How a Missing Secret Made Agent Tool Credentials Predictable, and How We Made It Fail Closed</title>
      <dc:creator>NieJingChuan</dc:creator>
      <pubDate>Mon, 20 Jul 2026 09:56:34 +0000</pubDate>
      <link>https://dev.to/gangan/how-a-missing-secret-made-agent-tool-credentials-predictable-and-how-we-made-it-fail-closed-44p7</link>
      <guid>https://dev.to/gangan/how-a-missing-secret-made-agent-tool-credentials-predictable-and-how-we-made-it-fail-closed-44p7</guid>
      <description>&lt;p&gt;&lt;em&gt;This is a submission for &lt;a href="https://dev.to/bugsmash"&gt;DEV's Summer Bug Smash: Clear the Lineup&lt;/a&gt; powered by &lt;a href="https://sentry.io/" rel="noopener noreferrer"&gt;Sentry&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Project Overview
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://github.com/bailinghub/bailinghub" rel="noopener noreferrer"&gt;BailingHub&lt;/a&gt; is a self-hosted control plane for AI agents that operate existing business systems.&lt;/p&gt;

&lt;p&gt;It sits between an agent runtime and business APIs, where it can restrict tool exposure, carry a trusted acting subject, pause sensitive operations for approval, enforce execution limits, and preserve an audit trail. It is not the final business authorization layer: the business system still decides whether a concrete subject may perform a concrete action against current data.&lt;/p&gt;

&lt;p&gt;That position makes credential boundaries especially important. BailingHub issues task-scoped credentials for executor-to-hub tool calls and signs outbound callbacks and operational webhooks. Those signatures are derived from deployment secrets. If the root secret is not actually secret, the surrounding cryptography can look correct while providing much less assurance than operators expect.&lt;/p&gt;

&lt;p&gt;This post describes a real defect fixed in &lt;a href="https://github.com/bailinghub/bailinghub/pull/10" rel="noopener noreferrer"&gt;PR #10&lt;/a&gt; and released as &lt;a href="https://github.com/bailinghub/bailinghub/releases/tag/v0.1.2" rel="noopener noreferrer"&gt;BailingHub v0.1.2&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Bug Fix or Performance Improvement
&lt;/h2&gt;

&lt;h3&gt;
  
  
  The bug was one convenient fallback
&lt;/h3&gt;

&lt;p&gt;Task-scoped tool credentials were derived using HMAC-SHA256:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="cm"&gt;/** Task-scoped tool credential: HMAC(server.token, job_id.claim_token). */&lt;/span&gt;
&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;toolTokenFor&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;jobId&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;claimToken&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;serverToken&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nf"&gt;createHmac&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;sha256&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;serverToken&lt;/span&gt; &lt;span class="o"&gt;||&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;bailing&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
    &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;update&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;`&lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;jobId&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;.&lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;claimToken&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;`&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
    &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;digest&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;hex&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The fallback made local setup convenient. If &lt;code&gt;server.token&lt;/code&gt; was missing, the application could still derive a token and continue running.&lt;/p&gt;

&lt;p&gt;But &lt;code&gt;bailing&lt;/code&gt; was a public literal in an open-source repository. It was not a secret.&lt;/p&gt;

&lt;p&gt;The same pattern also appeared in fallback paths for job callback signatures and alert webhooks. This meant a deployment mistake did not produce a loud startup failure. It silently changed a secret-key operation into one using a globally known key.&lt;/p&gt;

&lt;p&gt;HMAC itself was not broken. The key management was.&lt;/p&gt;

&lt;p&gt;An attacker would still need the message inputs for a particular signature. For task-scoped credentials, those inputs include the job and claim values. The defect therefore did &lt;strong&gt;not&lt;/strong&gt; mean that every deployment was automatically compromised or that arbitrary credentials could be forged from a job ID alone.&lt;/p&gt;

&lt;p&gt;The security property that failed was more precise:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Whenever the fallback was active, anyone who obtained the signed message inputs could reproduce the MAC because the supposed root secret was public.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;For a control plane that uses signatures as evidence across trust boundaries, silently accepting that state was not defensible.&lt;/p&gt;

&lt;h3&gt;
  
  
  Why a startup-only check was not enough
&lt;/h3&gt;

&lt;p&gt;The obvious patch was to reject a missing token during configuration loading. That would have fixed the current startup path, but it would leave a fragile invariant:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;"Every future caller must remember that config validation already happened."
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Security-sensitive code tends to grow new entry points: tests instantiate partial dependencies, maintenance scripts call lower-level functions, and later refactors move signing logic. If a signing helper can still manufacture a credential from an empty secret, a future path can accidentally restore the old failure mode.&lt;/p&gt;

&lt;p&gt;We therefore treated the fix as two separate boundaries:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Deployment policy:&lt;/strong&gt; unsafe exposed deployments must not start.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Cryptographic use:&lt;/strong&gt; a signing path must not operate without a real secret, even if configuration validation was bypassed.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;That distinction shaped the final patch.&lt;/p&gt;

&lt;h2&gt;
  
  
  Code
&lt;/h2&gt;

&lt;p&gt;The complete change is public in &lt;a href="https://github.com/bailinghub/bailinghub/pull/10" rel="noopener noreferrer"&gt;bailinghub/bailinghub#10&lt;/a&gt;. The core fix has four parts.&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Centralize the deployment policy
&lt;/h3&gt;

&lt;p&gt;We introduced one policy module for the server root token:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;MIN_EXTERNAL_TOKEN_LENGTH&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;24&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

&lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;KNOWN_WEAK_TOKENS&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nc"&gt;Set&lt;/span&gt;&lt;span class="p"&gt;([&lt;/span&gt;
  &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;bailing&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;bailing-dev-admin-token-change-me&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;change-me&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;changeme&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;replace-me&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;replace_with_a_long_random_secret&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;replace-with-a-long-random-secret&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;secret&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;token&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
&lt;span class="p"&gt;]);&lt;/span&gt;

&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;isLoopbackHost&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;host&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt; &lt;span class="nx"&gt;boolean&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;normalized&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;String&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;host&lt;/span&gt; &lt;span class="o"&gt;??&lt;/span&gt; &lt;span class="dl"&gt;''&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
    &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;trim&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
    &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;toLowerCase&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
    &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;replace&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sr"&gt;/^&lt;/span&gt;&lt;span class="se"&gt;\[&lt;/span&gt;&lt;span class="sr"&gt;|&lt;/span&gt;&lt;span class="se"&gt;\]&lt;/span&gt;&lt;span class="sr"&gt;$/g&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;''&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nx"&gt;normalized&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;localhost&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;
    &lt;span class="o"&gt;||&lt;/span&gt; &lt;span class="nx"&gt;normalized&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;::1&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;
    &lt;span class="o"&gt;||&lt;/span&gt; &lt;span class="nx"&gt;normalized&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;0:0:0:0:0:0:0:1&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;
    &lt;span class="o"&gt;||&lt;/span&gt; &lt;span class="nx"&gt;normalized&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;::ffff:127.0.0.1&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;
    &lt;span class="o"&gt;||&lt;/span&gt; &lt;span class="sr"&gt;/^127&lt;/span&gt;&lt;span class="se"&gt;(?:\.\d{1,3}){3}&lt;/span&gt;&lt;span class="sr"&gt;$/&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;test&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;normalized&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;allowsUnauthenticatedLocalDevelopment&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
  &lt;span class="nx"&gt;env&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;development&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt; &lt;span class="o"&gt;|&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;production&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nx"&gt;host&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
&lt;span class="p"&gt;):&lt;/span&gt; &lt;span class="nx"&gt;boolean&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nx"&gt;env&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;development&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; &lt;span class="nf"&gt;isLoopbackHost&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;host&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The important part is that “development” is not enough. A process listening on &lt;code&gt;0.0.0.0&lt;/code&gt; is exposed beyond the local machine even if &lt;code&gt;NODE_ENV&lt;/code&gt; or an application flag says development.&lt;/p&gt;

&lt;p&gt;Tokenless startup is therefore allowed only when both conditions are true:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;development mode AND loopback listener
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Production mode or any non-loopback listener must provide an explicit token. Exposed deployments also reject values shorter than 24 characters and known public placeholders.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;assertServerTokenPolicy&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;input&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;env&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;development&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt; &lt;span class="o"&gt;|&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;production&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;host&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;token&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}):&lt;/span&gt; &lt;span class="k"&gt;void&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;token&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;String&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;input&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;token&lt;/span&gt; &lt;span class="o"&gt;??&lt;/span&gt; &lt;span class="dl"&gt;''&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;trim&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;

  &lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;!&lt;/span&gt;&lt;span class="nx"&gt;token&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nf"&gt;allowsUnauthenticatedLocalDevelopment&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;input&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;env&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;input&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;host&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt; &lt;span class="k"&gt;return&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="k"&gt;throw&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nc"&gt;Error&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;BAILING_TOKEN is required for production or non-loopback listeners&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;

  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;exposed&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nx"&gt;input&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;env&lt;/span&gt; &lt;span class="o"&gt;===&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;production&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt; &lt;span class="o"&gt;||&lt;/span&gt; &lt;span class="o"&gt;!&lt;/span&gt;&lt;span class="nf"&gt;isLoopbackHost&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;input&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;host&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;!&lt;/span&gt;&lt;span class="nx"&gt;exposed&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;return&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

  &lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;token&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;length&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt; &lt;span class="nx"&gt;MIN_EXTERNAL_TOKEN_LENGTH&lt;/span&gt; &lt;span class="o"&gt;||&lt;/span&gt; &lt;span class="nx"&gt;KNOWN_WEAK_TOKENS&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;has&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nf"&gt;normalizedWeakToken&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;token&lt;/span&gt;&lt;span class="p"&gt;)))&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;throw&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nc"&gt;Error&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;BAILING_TOKEN must be strong and must not use a public placeholder&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The error text above is translated for this article; the &lt;a href="https://github.com/bailinghub/bailinghub/blob/v0.1.2/src/core/platform/server-token.ts" rel="noopener noreferrer"&gt;source implementation&lt;/a&gt; carries the same policy with operator-facing Chinese diagnostics.&lt;/p&gt;

&lt;h3&gt;
  
  
  2. Fail closed again at the cryptographic boundary
&lt;/h3&gt;

&lt;p&gt;The second guard is deliberately small:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="k"&gt;export&lt;/span&gt; &lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;requireServerToken&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;token&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;purpose&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;value&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;String&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;token&lt;/span&gt; &lt;span class="o"&gt;??&lt;/span&gt; &lt;span class="dl"&gt;''&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;trim&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
  &lt;span class="k"&gt;if &lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;!&lt;/span&gt;&lt;span class="nx"&gt;value&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;throw&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nc"&gt;Error&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;`BAILING_TOKEN is not configured; cannot &lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;purpose&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;`&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nx"&gt;value&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Credential derivation now requires that guard:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;toolTokenFor&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;jobId&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;claimToken&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nx"&gt;serverToken&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt; &lt;span class="kr"&gt;string&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nf"&gt;createHmac&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
    &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;sha256&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nf"&gt;requireServerToken&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;serverToken&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;issue a task-scoped tool credential&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
  &lt;span class="p"&gt;)&lt;/span&gt;
    &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;update&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;`&lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;jobId&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;.&lt;/span&gt;&lt;span class="p"&gt;${&lt;/span&gt;&lt;span class="nx"&gt;claimToken&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;`&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
    &lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;digest&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;hex&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Callback and alert-webhook fallback paths use the same requirement. No signing path is allowed to substitute a public constant.&lt;/p&gt;

&lt;p&gt;This is intentional defense in depth. Startup validation protects the deployment. Use-site validation protects the cryptographic invariant.&lt;/p&gt;

&lt;h3&gt;
  
  
  3. Remove predictable deployment defaults
&lt;/h3&gt;

&lt;p&gt;Both source and prebuilt-image Compose files previously made it possible to receive a public default token through interpolation. Those defaults were removed.&lt;/p&gt;

&lt;p&gt;Operators now generate a secret explicitly:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;export &lt;/span&gt;&lt;span class="nv"&gt;BAILING_TOKEN&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="si"&gt;$(&lt;/span&gt;openssl rand &lt;span class="nt"&gt;-hex&lt;/span&gt; 32&lt;span class="si"&gt;)&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;
docker compose up &lt;span class="nt"&gt;--build&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The official installer generates and persists a random token. The important word is &lt;strong&gt;persists&lt;/strong&gt;: generating a different value on every restart would invalidate credentials and break integrations.&lt;/p&gt;

&lt;h3&gt;
  
  
  4. Turn the policy into regression tests and release gates
&lt;/h3&gt;

&lt;p&gt;The tests cover the boundary matrix rather than only the original string:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="nf"&gt;test&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;only development loopback may run without a token&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nx"&gt;assert&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;doesNotThrow&lt;/span&gt;&lt;span class="p"&gt;(()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nf"&gt;assertServerTokenPolicy&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
    &lt;span class="na"&gt;env&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;development&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="na"&gt;host&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;127.0.0.1&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="na"&gt;token&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;''&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="p"&gt;}));&lt;/span&gt;

  &lt;span class="nx"&gt;assert&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;throws&lt;/span&gt;&lt;span class="p"&gt;(()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nf"&gt;assertServerTokenPolicy&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
    &lt;span class="na"&gt;env&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;development&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="na"&gt;host&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;0.0.0.0&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="na"&gt;token&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;''&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="p"&gt;}));&lt;/span&gt;

  &lt;span class="nx"&gt;assert&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;throws&lt;/span&gt;&lt;span class="p"&gt;(()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nf"&gt;assertServerTokenPolicy&lt;/span&gt;&lt;span class="p"&gt;({&lt;/span&gt;
    &lt;span class="na"&gt;env&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;production&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="na"&gt;host&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;127.0.0.1&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="na"&gt;token&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="dl"&gt;''&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="p"&gt;}));&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;

&lt;span class="nf"&gt;test&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;signing paths fail closed without a configured secret&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nx"&gt;assert&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;throws&lt;/span&gt;&lt;span class="p"&gt;(()&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="nf"&gt;requireServerToken&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;''&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;sign a test message&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="p"&gt;));&lt;/span&gt;
&lt;span class="p"&gt;});&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The resulting behavior is explicit:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Environment&lt;/th&gt;
&lt;th&gt;Listener&lt;/th&gt;
&lt;th&gt;Token&lt;/th&gt;
&lt;th&gt;Result&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Development&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;127.0.0.1&lt;/code&gt;, &lt;code&gt;localhost&lt;/code&gt;, or &lt;code&gt;::1&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;Empty&lt;/td&gt;
&lt;td&gt;Allowed for local-only development&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Development&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;0.0.0.0&lt;/code&gt; or another non-loopback address&lt;/td&gt;
&lt;td&gt;Empty&lt;/td&gt;
&lt;td&gt;Startup rejected&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Production&lt;/td&gt;
&lt;td&gt;Any address&lt;/td&gt;
&lt;td&gt;Empty&lt;/td&gt;
&lt;td&gt;Startup rejected&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Production or exposed development&lt;/td&gt;
&lt;td&gt;Any address&lt;/td&gt;
&lt;td&gt;Known placeholder or short value&lt;/td&gt;
&lt;td&gt;Startup rejected&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Production or exposed development&lt;/td&gt;
&lt;td&gt;Any address&lt;/td&gt;
&lt;td&gt;Strong explicit value&lt;/td&gt;
&lt;td&gt;Allowed&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Any signing path&lt;/td&gt;
&lt;td&gt;Any address&lt;/td&gt;
&lt;td&gt;Empty&lt;/td&gt;
&lt;td&gt;Operation rejected, never silently signed&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h2&gt;
  
  
  My Improvements
&lt;/h2&gt;

&lt;h3&gt;
  
  
  The patch closed more than the reported line
&lt;/h3&gt;

&lt;p&gt;Replacing this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="nx"&gt;serverToken&lt;/span&gt; &lt;span class="o"&gt;||&lt;/span&gt; &lt;span class="dl"&gt;'&lt;/span&gt;&lt;span class="s1"&gt;bailing&lt;/span&gt;&lt;span class="dl"&gt;'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;with this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight typescript"&gt;&lt;code&gt;&lt;span class="nx"&gt;serverToken&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;would only move the bug. Node's HMAC API can still accept an empty string as a key. The code would look cleaner while unsafe configuration remained operational.&lt;/p&gt;

&lt;p&gt;The completed fix instead establishes a reusable invariant:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;An exposed deployment cannot start with a missing or known-weak root token,
and no credential or signature can be produced from an absent root token.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That invariant is enforced across configuration, task credentials, callbacks, alert webhooks, Compose defaults, installation guidance, tests, and the security scanner.&lt;/p&gt;

&lt;h3&gt;
  
  
  Compatibility was kept narrow and explicit
&lt;/h3&gt;

&lt;p&gt;Security fixes can become adoption hazards when they unexpectedly break the fastest local workflow. We kept one constrained compatibility exception:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;local loopback development may remain tokenless;&lt;/li&gt;
&lt;li&gt;LAN, container-exposed, and production deployments may not;&lt;/li&gt;
&lt;li&gt;existing deployments with strong secrets continue unchanged;&lt;/li&gt;
&lt;li&gt;the public HTTP API, SDK contracts, HMAC wire format, and database schema did not change.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;No database migration was required.&lt;/p&gt;

&lt;h3&gt;
  
  
  Validation
&lt;/h3&gt;

&lt;p&gt;The public PR records the following validation:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;npm run release:check&lt;/code&gt;;&lt;/li&gt;
&lt;li&gt;310 TypeScript tests;&lt;/li&gt;
&lt;li&gt;frontend production build;&lt;/li&gt;
&lt;li&gt;dependency audits;&lt;/li&gt;
&lt;li&gt;documentation and example checks;&lt;/li&gt;
&lt;li&gt;PHP, PHP 7, Node.js, and Python SDK checks;&lt;/li&gt;
&lt;li&gt;open-source export and GitHub repository rehearsal;&lt;/li&gt;
&lt;li&gt;Docker Compose configuration with a generated token.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The fix was released immediately as &lt;a href="https://github.com/bailinghub/bailinghub/releases/tag/v0.1.2" rel="noopener noreferrer"&gt;v0.1.2&lt;/a&gt;, with upgrade guidance for operators.&lt;/p&gt;

&lt;h2&gt;
  
  
  What We Learned
&lt;/h2&gt;

&lt;h3&gt;
  
  
  A default secret is part of the security protocol
&lt;/h3&gt;

&lt;p&gt;Default values often look like configuration ergonomics. For credentials, they are protocol behavior.&lt;/p&gt;

&lt;p&gt;If the application silently selects a public key, every correctly implemented HMAC call inherits that decision. The cryptographic primitive cannot repair bad secret provenance.&lt;/p&gt;

&lt;h3&gt;
  
  
  “Development mode” is not a network boundary
&lt;/h3&gt;

&lt;p&gt;A development flag says something about intent. The listener address says something about exposure.&lt;/p&gt;

&lt;p&gt;The safe exception had to combine both. &lt;code&gt;development + 0.0.0.0&lt;/code&gt; is not equivalent to &lt;code&gt;development + 127.0.0.1&lt;/code&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Validate at startup and at the point of use
&lt;/h3&gt;

&lt;p&gt;Startup validation gives operators a clear failure and prevents an unsafe service from becoming reachable. Point-of-use validation prevents future internal callers from bypassing the invariant.&lt;/p&gt;

&lt;p&gt;Neither guard replaces the other.&lt;/p&gt;

&lt;h3&gt;
  
  
  Fail closed does not have to destroy local usability
&lt;/h3&gt;

&lt;p&gt;The solution was not “require production ceremony everywhere.” It was to make the exception precise:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;zero-config local loopback development: yes
silent public or production fallback: no
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That is a much smaller and more defensible compatibility surface than a globally known secret.&lt;/p&gt;

&lt;h2&gt;
  
  
  Links
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://github.com/bailinghub/bailinghub" rel="noopener noreferrer"&gt;BailingHub repository&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/bailinghub/bailinghub/pull/10" rel="noopener noreferrer"&gt;Security fix PR #10&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/bailinghub/bailinghub/releases/tag/v0.1.2" rel="noopener noreferrer"&gt;BailingHub v0.1.2 release&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/bailinghub/bailinghub/blob/v0.1.2/src/core/platform/server-token.ts" rel="noopener noreferrer"&gt;v0.1.2 server-token policy&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The useful part of this fix was not deleting one fallback string. It was turning an implicit assumption into an invariant that can be read, tested, and enforced at every consequential boundary.&lt;/p&gt;

</description>
      <category>devchallenge</category>
      <category>bugsmash</category>
      <category>security</category>
      <category>opensource</category>
    </item>
    <item>
      <title>We Need a Name for When AI Agents Start Operating Existing Business Systems</title>
      <dc:creator>NieJingChuan</dc:creator>
      <pubDate>Sat, 18 Jul 2026 13:06:30 +0000</pubDate>
      <link>https://dev.to/gangan/we-need-a-name-for-when-ai-agents-start-operating-existing-business-systems-2gn7</link>
      <guid>https://dev.to/gangan/we-need-a-name-for-when-ai-agents-start-operating-existing-business-systems-2gn7</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;We are moving from a world in which people operate software step by step to one in which people state goals and agents enter existing systems to carry them out. This essay proposes &lt;strong&gt;A2B, Agent-to-Business&lt;/strong&gt;, as a working concept for naming that emerging relationship.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;When a team says, "We want to connect AI to our existing business systems," the sentence can mean almost anything.&lt;/p&gt;

&lt;p&gt;A product manager may imagine a conversational interface. An AI team may think about models, retrieval, and context. A developer may think about function calling, an MCP server, or internal APIs. A security team may think about identity, authorization, and audit. The business owner may simply expect the system to read orders, update inventory, create tickets, process refunds, or reschedule appointments.&lt;/p&gt;

&lt;p&gt;None of these interpretations is wrong. Each describes one part of the same change.&lt;/p&gt;

&lt;p&gt;What remains difficult to say in one sentence is this:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;An agent receives a goal from a person or an organization, enters a business system that already exists, reads business facts, selects an operational path, and completes work that once required a person to understand an interface and act through it.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;If every serious conversation must repeat that entire paragraph, the problem may not be only a missing technical solution. We may also be missing a category.&lt;/p&gt;

&lt;p&gt;We already use short terms such as B2B, B2C, and B2B2C to compress complex market relationships. We can use A2A to discuss collaboration between agents. But when we try to describe agents entering existing software and producing real business outcomes, we fall back on loose phrases: &lt;em&gt;AI integration&lt;/em&gt;, &lt;em&gt;tool use&lt;/em&gt;, &lt;em&gt;LLM calling APIs&lt;/em&gt;, &lt;em&gt;enterprise automation&lt;/em&gt;, &lt;em&gt;MCP adoption&lt;/em&gt;, &lt;em&gt;an AI assistant for operations&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;Each phrase touches the phenomenon. None identifies it completely.&lt;/p&gt;

&lt;p&gt;This essay calls it &lt;strong&gt;A2B: Agent-to-Business&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;A2B is not presented here as an established industry standard, a protocol, or a product category that everyone has already agreed to use. It is a &lt;strong&gt;working concept&lt;/strong&gt;: a name for situations in which an agent acts under delegation, crosses into an existing business system, invokes real operational capabilities, and produces outcomes for which people or organizations remain accountable.&lt;/p&gt;

&lt;p&gt;The purpose of naming the relationship is not to add another acronym to an already crowded field. It is to make a recurring but fragmented problem visible enough to examine as a whole.&lt;/p&gt;

&lt;h2&gt;
  
  
  Categories are infrastructure for collective thoughtå
&lt;/h2&gt;

&lt;p&gt;Technical communities often treat language as packaging applied after the real engineering is finished. In practice, stable categories are part of the infrastructure through which engineering knowledge accumulates.&lt;/p&gt;

&lt;p&gt;Without a shared name, a problem can exist only inside individual projects. A commerce team calls it an AI refund assistant. A CRM team calls it an autonomous sales operator. An HR team calls it an employee service agent. An operations team calls it automated incident handling.&lt;/p&gt;

&lt;p&gt;These teams may be confronting the same architectural questions without recognizing that they are working on the same class of system:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;How does the agent learn which business capabilities exist?&lt;/li&gt;
&lt;li&gt;Is it offering advice, preparing a draft, or taking an official action?&lt;/li&gt;
&lt;li&gt;Whose identity is represented when it acts?&lt;/li&gt;
&lt;li&gt;Why did a natural-language goal become this particular sequence of operations?&lt;/li&gt;
&lt;li&gt;Which consequences may be produced automatically, and which must return to a person?&lt;/li&gt;
&lt;li&gt;If the result is wrong, can the organization reconstruct the chain of responsibility?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;When these questions remain "integration details," every organization has to rediscover them. The knowledge stays trapped in product-specific configurations, internal prompts, gateway rules, and incident reports.&lt;/p&gt;

&lt;p&gt;A useful category changes that. It lets product managers, developers, architects, security teams, and business owners see that they are not merely adding an AI feature. They are designing a new relationship between intention, software, action, and responsibility.&lt;/p&gt;

&lt;p&gt;A durable category should have at least three properties:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Compression.&lt;/strong&gt; It should reduce many recurring situations to a short concept without discarding their essential structure.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Distinction.&lt;/strong&gt; It should clarify what belongs to the category, what does not, and how it differs from adjacent concepts.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Generativity.&lt;/strong&gt; It should help us ask questions that were previously difficult to formulate and derive claims that practice can test.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The value of A2B therefore does not depend on whether the acronym becomes fashionable. The more serious test is whether it can reveal a common structure across commerce, CRM, healthcare, public services, AI operating systems, robotics, and multi-agent systems; whether it can distinguish that structure from chat, content generation, fixed automation, and pure agent-to-agent coordination; and whether it helps us anticipate how software and organizational responsibility may change.&lt;/p&gt;

&lt;p&gt;If it cannot do those things, it is only a label. If it can, it becomes a cognitive tool.&lt;/p&gt;

&lt;h2&gt;
  
  
  The important change is not that AI can call an API
&lt;/h2&gt;

&lt;p&gt;At first glance, A2B may sound like a new term for "an LLM calling an API." That would be too shallow.&lt;/p&gt;

&lt;p&gt;Software has called software for decades. Workflow engines, scripts, RPA systems, schedulers, and integration platforms already update orders, synchronize inventory, send notifications, and trigger approvals.&lt;/p&gt;

&lt;p&gt;Nor did machines begin making consequential decisions with modern agents. Algorithmic trading, fraud detection, industrial control, recommendation systems, and autonomous vehicles have long selected actions from data.&lt;/p&gt;

&lt;p&gt;What agents change is not the existence of machine action. They change its &lt;strong&gt;generality, openness, and accessibility&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Earlier automated decision systems usually operated inside domains whose inputs, objectives, state spaces, and available actions had been carefully modeled in advance. A specialized team defined the path before the system ran.&lt;/p&gt;

&lt;p&gt;A general-purpose agent can instead receive a goal that was never encoded as a complete procedure, discover or select from heterogeneous tools, construct arguments, inspect intermediate results, and revise its next step.&lt;/p&gt;

&lt;p&gt;Traditional automation often begins with an execution path:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;developers predefine the condition
  -&amp;gt; workflow designers arrange the steps
  -&amp;gt; parameters come from deterministic mappings
  -&amp;gt; the program executes the known procedure
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;An agent may begin with only an intended outcome:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;a person states a goal
  -&amp;gt; the agent interprets the goal
  -&amp;gt; the agent selects capabilities
  -&amp;gt; the agent constructs arguments and an action order
  -&amp;gt; the agent observes intermediate results
  -&amp;gt; the agent decides what to do next
  -&amp;gt; the business system produces an official result
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Both chains may use the same API. They do not have the same action structure.&lt;/p&gt;

&lt;p&gt;The first mainly delegates execution. The second delegates part of the translation from intention to operational path.&lt;/p&gt;

&lt;p&gt;This does not mean an agent possesses human will, moral agency, or legal personhood. It remains software deployed by people and organizations. Responsibility cannot be transferred to a model merely because the model participated in reasoning.&lt;/p&gt;

&lt;p&gt;But an important engineering fact has changed: a non-human component now participates in deciding how a goal becomes an operation.&lt;/p&gt;

&lt;p&gt;When AI mainly generates answers, evaluation centers on epistemic quality: Is the output accurate, relevant, grounded, or biased?&lt;/p&gt;

&lt;p&gt;When an agent enters a business system, another dimension appears: Is the action legitimate? Was it authorized? Did it remain faithful to the original delegation? Could it have been stopped or reversed? Who is accountable for the outcome?&lt;/p&gt;

&lt;p&gt;An answer can be factually correct and still lead to an action that should never occur. A parameter can satisfy every schema rule and still be illegitimate because the acting subject, current business state, or authority is wrong.&lt;/p&gt;

&lt;p&gt;A2B marks the boundary at which AI output becomes institutional action.&lt;/p&gt;

&lt;h2&gt;
  
  
  From human-operated software to agent-operated software
&lt;/h2&gt;

&lt;p&gt;Most of the history of software interfaces has been about improving how people operate machines.&lt;/p&gt;

&lt;p&gt;Command lines required people to learn machine-oriented languages. Graphical interfaces organized operations into windows, forms, menus, and buttons. Mobile computing made those interfaces continuously available. Natural language reduced the effort required to express intent.&lt;/p&gt;

&lt;p&gt;These interfaces will coexist for a long time. But agents introduce a change in direction:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;The direct operator of software is expanding from humans to agents.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The familiar business path looks like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;a person understands the business goal
  -&amp;gt; logs into a system
  -&amp;gt; finds the correct function
  -&amp;gt; enters parameters
  -&amp;gt; submits the operation
  -&amp;gt; the system validates and executes it
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The emerging path may look like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;a person expresses the business goal
  -&amp;gt; an agent interprets it
  -&amp;gt; the agent selects a business capability
  -&amp;gt; the agent constructs operational arguments
  -&amp;gt; the system validates and executes
  -&amp;gt; the agent continues from the result
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is more than replacing clicks with tool calls.&lt;/p&gt;

&lt;p&gt;Historically, a business system exposed functions to people through pages, menus, and buttons. Increasingly, it will also need to expose functions to agents through structured capabilities, machine-readable semantics, and reliable execution feedback.&lt;/p&gt;

&lt;p&gt;Conversation is only the human entry point. The decisive change happens after the conversation: how a goal enters a business process, how it becomes an action, and how the result returns to the sphere of human responsibility.&lt;/p&gt;

&lt;h2&gt;
  
  
  What A2B describes
&lt;/h2&gt;

&lt;p&gt;A2B can be understood at three levels.&lt;/p&gt;

&lt;p&gt;The plain-language definition is:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;People used to open software and perform the steps themselves. A2B describes a person stating a goal and an agent entering existing business systems to get the work done.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The engineering definition is:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;A2B describes situations in which an agent, acting under human or organizational delegation, uses capabilities provided by existing business systems to read business facts, organize operations, and produce traceable business outcomes.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The structural definition is:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;A2B is a relationship in which an agent crosses a software, organizational, or trust boundary and participates in a real business process.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The shared structure can be compressed into three elements:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;A2B = semantic delegation + boundary crossing + institutional consequence
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Semantic delegation
&lt;/h3&gt;

&lt;p&gt;The person or organization supplies a goal rather than a complete sequence of steps. The agent participates in translating that goal into capabilities, arguments, and an order of action.&lt;/p&gt;

&lt;h3&gt;
  
  
  Boundary crossing
&lt;/h3&gt;

&lt;p&gt;The action moves from the agent's environment into another system with its own identities, data, policies, and responsibilities. That boundary may surround an application, an enterprise, a public institution, or an external trust domain.&lt;/p&gt;

&lt;h3&gt;
  
  
  Institutional consequence
&lt;/h3&gt;

&lt;p&gt;The result is not merely model output. It becomes a fact recognized by an organization: a refund was created, an employee record was changed, an appointment was cancelled, an application was submitted, inventory was deducted, or a work order was closed.&lt;/p&gt;

&lt;p&gt;Institutional consequence is not limited to writes. Reading a private order, medical record, account, or employee file changes who possesses protected information and creates duties of confidentiality, use, and traceability. A2B consequences include both changes to business state and access to constrained business facts.&lt;/p&gt;

&lt;p&gt;These elements are descriptive, not prescriptive. Naming A2B does not require every deployment to adopt the same protocol, identity format, approval workflow, or governance model. It first tells us what kind of relationship is forming. Different organizations can then decide how that relationship should be governed.&lt;/p&gt;

&lt;h2&gt;
  
  
  "Business" does not mean commerce alone
&lt;/h2&gt;

&lt;p&gt;The word &lt;em&gt;Business&lt;/em&gt; in A2B should be read broadly as &lt;strong&gt;business systems and institutional processes&lt;/strong&gt;, not only as for-profit commerce.&lt;/p&gt;

&lt;p&gt;The relevant systems include ERP, CRM, HR, finance, support, production, healthcare, education, government, and public-service systems. Their shared characteristic is that they maintain real states recognized by an organization: whether an order was refunded, an employee is active, inventory was allocated, a medical request was updated, a permit was approved, or a case was closed.&lt;/p&gt;

&lt;p&gt;A modern business system is not merely a database that stores passive information. It is an executable carrier of institutional rules.&lt;/p&gt;

&lt;p&gt;Permissions, workflows, obligations, and responsibilities are encoded in accounts, roles, state machines, approvals, records, and business logic. A changed database row may be a technical event. When that row means "the refund exists," "the employee has left," "the contract is active," or "the treatment was approved," it is also an institutional fact.&lt;/p&gt;

&lt;p&gt;An agent entering such a system is therefore doing more than crossing an API boundary. It is moving from computational space into institutional space. Model-generated arguments, after validation and execution, become states that affect resources, rights, obligations, and accountability.&lt;/p&gt;

&lt;p&gt;That is why this relationship deserves to be identified separately. A2B sits between &lt;strong&gt;what a machine computes&lt;/strong&gt; and &lt;strong&gt;what an organization recognizes as having happened&lt;/strong&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  What is not A2B
&lt;/h2&gt;

&lt;p&gt;A category only becomes useful when it can exclude things.&lt;/p&gt;

&lt;p&gt;Ordinary content generation is not usually A2B. Asking a model to write an article, create an image, or rewrite copy may produce valuable output, but the model has not thereby entered an existing business process.&lt;/p&gt;

&lt;p&gt;Answering public knowledge questions is not a typical A2B action. The activity remains primarily in the information domain.&lt;/p&gt;

&lt;p&gt;Model training, inference services, and vector retrieval are not themselves A2B. They may support an A2B system, but they do not constitute the relationship.&lt;/p&gt;

&lt;p&gt;Pure A2A collaboration is not automatically A2B. Agents can exchange tasks, capabilities, and intermediate results without entering a system that maintains official business state.&lt;/p&gt;

&lt;p&gt;Traditional automation overlaps with A2B but is not identical to it. A script that executes a fixed path is better described as automation. The more a system receives open-ended goals, chooses capabilities, constructs arguments, and adapts its path, the more clearly it displays the agent characteristics relevant to A2B.&lt;/p&gt;

&lt;p&gt;A2B also does not require full autonomy. Human confirmation does not make an action cease to be A2B. Autonomy describes how much of the path has been delegated, not whether the relationship exists.&lt;/p&gt;

&lt;h2&gt;
  
  
  A2B is adjacent to MCP, A2A, RPA, and Agent Commerce, but not identical to them
&lt;/h2&gt;

&lt;p&gt;Several existing terms describe important parts of the landscape:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Concept&lt;/th&gt;
&lt;th&gt;Primary object of description&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;B2B / B2C / B2B2C&lt;/td&gt;
&lt;td&gt;Commercial relationships between market participants&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;A2A&lt;/td&gt;
&lt;td&gt;Communication and collaboration between agents&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;API / MCP / SDK&lt;/td&gt;
&lt;td&gt;How capabilities are described, discovered, connected, or invoked&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;RPA / workflow automation&lt;/td&gt;
&lt;td&gt;How predefined automation steps are organized and executed&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Agent Commerce&lt;/td&gt;
&lt;td&gt;How agents participate in discovery, transactions, or payments&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;A2B, as used here&lt;/td&gt;
&lt;td&gt;How an agent enters an existing business system and performs accountable work&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;MCP may carry an A2B action, but connecting a tool is not the same as defining the relationship in which the tool is used.&lt;/p&gt;

&lt;p&gt;A2A may coordinate several agents before one of them enters an order, finance, healthcare, or production system. A complex task can contain many A2A interactions and still culminate in one or more A2B boundary crossings.&lt;/p&gt;

&lt;p&gt;RPA may automate the same business operation, but its path is usually predefined around an interface or workflow. A2B emphasizes semantic delegation and dynamic path selection.&lt;/p&gt;

&lt;p&gt;Agent Commerce may describe agents finding products, negotiating, purchasing, or making payments. A2B includes commercial scenarios but is broader: an agent reading a patient record, changing an employee status, or filing a public-service application is still crossing into an institutional system even when no market transaction occurs.&lt;/p&gt;

&lt;p&gt;These concepts are not rivals. They describe different axes of the same emerging stack.&lt;/p&gt;

&lt;h2&gt;
  
  
  A2B is a continuum of delegation, not an on/off switch
&lt;/h2&gt;

&lt;p&gt;Organizations will not wake up one morning and move from no agents to fully autonomous operations. Delegation will expand in stages.&lt;/p&gt;

&lt;h3&gt;
  
  
  Stage 0: information
&lt;/h3&gt;

&lt;p&gt;The agent answers from public content or a knowledge base without entering live business systems.&lt;/p&gt;

&lt;h3&gt;
  
  
  Stage 1: controlled reading
&lt;/h3&gt;

&lt;p&gt;The agent can query orders, inventory, customer records, cases, or tickets but cannot change state.&lt;/p&gt;

&lt;h3&gt;
  
  
  Stage 2: action proposals
&lt;/h3&gt;

&lt;p&gt;The agent uses business facts to prepare a recommendation, draft, or pending action that a person completes.&lt;/p&gt;

&lt;h3&gt;
  
  
  Stage 3: human-in-the-loop execution
&lt;/h3&gt;

&lt;p&gt;The agent selects capabilities and constructs arguments, but consequential steps pause for human review before execution.&lt;/p&gt;

&lt;h3&gt;
  
  
  Stage 4: bounded ongoing delegation
&lt;/h3&gt;

&lt;p&gt;Within explicit capability, identity, and responsibility boundaries, the agent continuously performs a class of business work and returns only exceptions or high-consequence decisions to people.&lt;/p&gt;

&lt;p&gt;A2B therefore matters long before full autonomy.&lt;/p&gt;

&lt;p&gt;The first time an agent reads private orders, the system must already know whom it represents and what it may see. When it prepares actions, the organization must distinguish suggestions from official acts. When it can submit a refund, delegation and traceability become central.&lt;/p&gt;

&lt;p&gt;A2B maturity is ultimately a measure of how much real business action an organization is both willing and able to delegate.&lt;/p&gt;

&lt;p&gt;Model quality is only one variable. Often, the factor preventing an organization from moving from reading to execution is not another benchmark point. It is the inability to explain and control the action chain.&lt;/p&gt;

&lt;h2&gt;
  
  
  Existing systems are the center of the problem
&lt;/h2&gt;

&lt;p&gt;It is tempting to imagine that enterprises will rebuild everything as AI-native software and leave old systems behind. Reality will be less clean.&lt;/p&gt;

&lt;p&gt;Orders, money, employees, customers, inventory, contracts, production, and public records already live inside systems that have accumulated years of data relationships, permissions, legal duties, and operating rules.&lt;/p&gt;

&lt;p&gt;Agents will not enter an empty world. They will enter an existing institutional order.&lt;/p&gt;

&lt;p&gt;That makes "legacy integration" a misleadingly small phrase. The hard problem is not only compatibility. It is allowing an agent to act inside an established system without asking that system to surrender its authority over identity, business state, and final outcomes.&lt;/p&gt;

&lt;p&gt;A new conversational interface may receive the goal. A new protocol may expose capabilities. A new runtime may organize the task. But the valid order state, account balance, employment relationship, approval record, or production status still belongs to the business system.&lt;/p&gt;

&lt;p&gt;One of the defining capabilities of future software may therefore be this:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Can the system expose clear, stable, and governable capabilities to agents while retaining its own business authority?&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  A2B is not tied to a screen, device, or protocol
&lt;/h2&gt;

&lt;p&gt;A2B first becomes urgent in enterprise software, but its structure is not limited to an admin console or a chat window.&lt;/p&gt;

&lt;p&gt;Software agents, AI operating systems, phone-level assistants, embodied robots, and multi-agent systems may have different sensors, actuators, and protocols. The test is not what device they run on. The test is whether semantic delegation, boundary crossing, and institutional consequence are present.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Carrier&lt;/th&gt;
&lt;th&gt;Usually outside A2B&lt;/th&gt;
&lt;th&gt;Potentially inside A2B&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Software agent&lt;/td&gt;
&lt;td&gt;Summarizing local documents or organizing personal files&lt;/td&gt;
&lt;td&gt;Creating a purchase order in ERP or changing a customer state in CRM&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;AI phone or operating system&lt;/td&gt;
&lt;td&gt;Adjusting screen brightness or starting a timer&lt;/td&gt;
&lt;td&gt;Entering airline, banking, healthcare, commerce, or government systems to make an accountable change&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Embodied robot&lt;/td&gt;
&lt;td&gt;Local navigation, motion planning, or obstacle avoidance&lt;/td&gt;
&lt;td&gt;Receiving inventory, confirming handoff, and updating WMS, ERP, or fulfillment state on behalf of an organization&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Multi-agent system&lt;/td&gt;
&lt;td&gt;Discussion, planning, and exchange of intermediate results&lt;/td&gt;
&lt;td&gt;A collaboration chain that ultimately performs an official action in a business system&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Physical action is not automatically more A2B than digital action. A robot navigating safely in a closed environment is primarily a robotics and control problem. A software agent reading a protected medical record may already have crossed a consequential institutional boundary.&lt;/p&gt;

&lt;p&gt;The same system can contain both A2B and non-A2B layers. A warehouse robot needs control systems to avoid collisions. When it claims inventory, records a handoff, and changes fulfillment state, it also enters a business relationship. The first layer concerns physical safety and control latency. The second concerns whom the robot represents, why it may act, who confirms the result, and how errors are traced.&lt;/p&gt;

&lt;p&gt;A2B does not replace robotics safety, operating-system security, identity infrastructure, or A2A protocols. It identifies the relationship that appears when those systems carry delegated action into the business world.&lt;/p&gt;

&lt;p&gt;As this relationship spreads, software competition may change as well. Applications have traditionally competed for human attention through screens, notifications, and branded interfaces. If agents become a primary entry point, services will increasingly compete to be correctly understood, selected, invoked, and completed by agents.&lt;/p&gt;

&lt;p&gt;That could shift part of digital distribution from control of the screen toward control of delegation, identity context, and task orchestration. This is not a completed fact, but it is an important possibility revealed by the A2B frame.&lt;/p&gt;

&lt;h2&gt;
  
  
  Once the category exists, an ecosystem can accumulate around it
&lt;/h2&gt;

&lt;p&gt;Categories are sometimes dismissed as marketing. At their best, they are coordinates around which research, engineering practice, investment, regulation, and community knowledge can accumulate.&lt;/p&gt;

&lt;p&gt;If A2B is recognized as a distinct problem, we can begin to ask systematically:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;At what stage of A2B maturity is an organization?&lt;/li&gt;
&lt;li&gt;Which business capabilities should be delegated first?&lt;/li&gt;
&lt;li&gt;What responsibilities belong to the agent, runtime, gateway, identity system, and business system?&lt;/li&gt;
&lt;li&gt;How should an A2B incident be classified and reconstructed?&lt;/li&gt;
&lt;li&gt;Which infrastructure needs recur across implementations?&lt;/li&gt;
&lt;li&gt;Which knowledge can be shared across industries, and which rules must remain local?&lt;/li&gt;
&lt;li&gt;Will cross-platform semantic and interoperability layers become necessary?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Without the category, the market sees isolated features: AI customer service, AI sales, AI finance, AI operations, AI phones, AI robots.&lt;/p&gt;

&lt;p&gt;With the category, we can recognize their common infrastructure problem: agents are being connected to real capabilities, and machine action must become something an organization can accept, constrain, and explain.&lt;/p&gt;

&lt;p&gt;The metrics of enterprise AI may change accordingly. Answer accuracy, model choice, and retrieval quality remain important. But once agents act, organizations will also need to measure:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;how many real workflows can be delegated;&lt;/li&gt;
&lt;li&gt;how many human steps are removed;&lt;/li&gt;
&lt;li&gt;which decisions still require human judgment;&lt;/li&gt;
&lt;li&gt;whether automation can expand without making responsibility ambiguous;&lt;/li&gt;
&lt;li&gt;whether failures can be stopped, explained, and recovered.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That is not merely an additional model benchmark. It is a different way of evaluating AI after it becomes part of production.&lt;/p&gt;

&lt;h2&gt;
  
  
  A useful concept should make falsifiable predictions
&lt;/h2&gt;

&lt;p&gt;Technology narratives become grand very easily. A serious concept should do more than redescribe the present. It should make claims that reality can later support or reject.&lt;/p&gt;

&lt;p&gt;If A2B identifies a durable relationship, we should gradually observe at least five developments.&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Software will develop interfaces for both people and agents
&lt;/h3&gt;

&lt;p&gt;Graphical interfaces will remain, but stable capability descriptions, machine entry points, and execution feedback will become first-class product surfaces rather than internal integration artifacts.&lt;/p&gt;

&lt;h3&gt;
  
  
  2. Enterprise AI maturity will be measured by delegable action
&lt;/h3&gt;

&lt;p&gt;Organizations will care less about how many models they have connected and more about which operational responsibilities can be safely delegated, how exceptions return to people, and whether the delegation boundary can expand.&lt;/p&gt;

&lt;h3&gt;
  
  
  3. AI governance will extend from output quality to action provenance
&lt;/h3&gt;

&lt;p&gt;It will not be enough to inspect what a model said. Organizations will need to know who initiated the goal, why the agent selected a capability, which identity it represented, how consequential arguments were formed, and where human decisions entered the chain.&lt;/p&gt;

&lt;h3&gt;
  
  
  4. An infrastructure layer will emerge between agents and business authority
&lt;/h3&gt;

&lt;p&gt;It may be implemented by agent platforms, gateways, cloud providers, business applications, or independent control planes. Its product shape may vary. But capability exposure, identity continuity, action constraints, human intervention, and accountability records will recur.&lt;/p&gt;

&lt;h3&gt;
  
  
  5. Competition for user attention will partly become competition for delegated choice
&lt;/h3&gt;

&lt;p&gt;When people express goals through agents, a service must be understandable and selectable by machines as well as visible to humans. Agent platforms may become a new distribution layer between intention and external capability.&lt;/p&gt;

&lt;p&gt;If none of this happens, if business software remains purely human-operated, if enterprise AI remains an information tool, and if organizations never need to reconstruct agent action chains, then A2B should be challenged as an unnecessary category.&lt;/p&gt;

&lt;p&gt;A concept that permits reality to prove it wrong is more useful than a slogan designed to survive every outcome.&lt;/p&gt;

&lt;h2&gt;
  
  
  From interface design to the institutional design of machine action
&lt;/h2&gt;

&lt;p&gt;Graphical interfaces changed how people use software. Mobile computing changed when and where they use it. Natural language changed how people express intent.&lt;/p&gt;

&lt;p&gt;Agents introduce a different question:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;When people no longer perform every software operation themselves, how should the relationship among intention, software, organizations, and responsibility be redesigned?&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The long-term significance is not that people click fewer buttons.&lt;/p&gt;

&lt;p&gt;Many jobs currently involve understanding a human goal and translating it into system operations. As agents assume more of that translation, human work may shift toward goal setting, exception judgment, responsibility, and institutional design.&lt;/p&gt;

&lt;p&gt;Software products may also be reorganized. Instead of being defined only by seats, pages, and workflows, some systems may be valued by how much work they allow people to delegate safely.&lt;/p&gt;

&lt;p&gt;The deeper issue is one of agency and responsibility.&lt;/p&gt;

&lt;p&gt;Human institutions have always depended on delegation. Employees act for organizations. Lawyers act for clients. Banks process funds under authorization. These relationships are governed by professional obligations, law, organizational controls, and the fact that the delegate remains a person who can bear responsibility.&lt;/p&gt;

&lt;p&gt;An AI agent can perform more and more functions associated with agency while remaining unable to assume moral or legal responsibility in the human sense. It can interpret a goal, select a capability, submit arguments, and advance a process. It cannot independently carry the obligation that made the delegation legitimate.&lt;/p&gt;

&lt;p&gt;This creates a &lt;strong&gt;machine-agency responsibility gap&lt;/strong&gt;: operational capacity moves into the technical chain, while accountability must remain with deployers, business owners, and human authorization structures.&lt;/p&gt;

&lt;p&gt;The more steps machines perform, the less acceptable it becomes to explain an outcome by saying, "the model decided." Organizations must instead explain who exposed the capability, who set the boundary, who allowed execution, and who owns the resulting institutional fact.&lt;/p&gt;

&lt;p&gt;A2B is where that gap becomes concrete. It turns abstract AI risk into a traceable action chain:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;information ends here; business action begins
tool connectivity ends here; organizational delegation begins
model output ends here; institutional consequence begins
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;A2B is not a complete answer to the governance of machine action. It is a coordinate for locating where the problem becomes unavoidable.&lt;/p&gt;

&lt;h2&gt;
  
  
  The name may change. The relationship will not disappear.
&lt;/h2&gt;

&lt;p&gt;A2B remains a proposed expression.&lt;/p&gt;

&lt;p&gt;The acronym already appears in other contexts, including agent-mediated commerce and payments. Another term may ultimately describe the broader relationship more clearly. The industry may absorb the problem into a larger discipline of agent infrastructure, digital delegation, or machine-action governance.&lt;/p&gt;

&lt;p&gt;A concept can have explanatory value without owning the future vocabulary.&lt;/p&gt;

&lt;p&gt;As long as people increasingly state goals rather than steps, agents increasingly choose tools and paths, business systems increasingly expose machine-operable capabilities, and organizations remain accountable for the results, this relationship will require a language.&lt;/p&gt;

&lt;p&gt;The carrier may change. The protocol may change. The final name may change.&lt;/p&gt;

&lt;p&gt;But the boundary between &lt;strong&gt;AI producing information&lt;/strong&gt; and &lt;strong&gt;agents entering the business world to act&lt;/strong&gt; will not disappear merely because we leave it unnamed.&lt;/p&gt;

&lt;h2&gt;
  
  
  A question for builders
&lt;/h2&gt;

&lt;p&gt;This proposal should be tested against real systems, not protected from disagreement.&lt;/p&gt;

&lt;p&gt;If you are building agents that read or change orders, accounts, staff records, inventory, healthcare workflows, production systems, or public services:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;What term do you currently use for this class of work?&lt;/li&gt;
&lt;li&gt;Where do you draw the boundary between agent assistance and agent-operated business action?&lt;/li&gt;
&lt;li&gt;Does the combination of semantic delegation, boundary crossing, and institutional consequence describe something that existing terms fail to isolate?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Alternative names, counterexamples, and boundary cases are useful evidence. A category becomes stronger by surviving precise criticism, not by avoiding it.&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion: we are naming a relationship, not a technology
&lt;/h2&gt;

&lt;p&gt;A2B matters not because the industry needs another acronym, but because a new relationship is beginning to take shape:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;people once learned and operated software
  -&amp;gt; people now state goals to agents
  -&amp;gt; agents enter software and complete work on their behalf
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Technically, that chain is composed of models, tools, protocols, runtimes, and business systems. Organizationally, it is a new division of labor. Socially, it means machine systems are entering human action chains in a more general, language-driven, and dynamically organized form.&lt;/p&gt;

&lt;p&gt;We need a name for this relationship because without shared language, product managers, developers, architects, security teams, and business owners will continue to rediscover the same problem from different directions.&lt;/p&gt;

&lt;p&gt;Once it becomes visible, the questions reorganize themselves: Which work should be delegated? Which capabilities should be exposed? Which decisions must remain human? How should software present itself to agents? How does responsibility return to people after machine-mediated action?&lt;/p&gt;

&lt;p&gt;The shortest definition is still the most useful:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;People used to open software and perform the work. A2B describes people stating goals and agents entering existing business systems to get the work done.&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;A2B may not be the final name.&lt;/p&gt;

&lt;p&gt;But if agents are moving from answering questions to acting on our behalf, the era this name points toward has already begun.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>architecture</category>
      <category>discuss</category>
      <category>security</category>
    </item>
    <item>
      <title>Why an AI Agent Must Never Choose Its Own Acting Subject</title>
      <dc:creator>NieJingChuan</dc:creator>
      <pubDate>Thu, 16 Jul 2026 04:44:57 +0000</pubDate>
      <link>https://dev.to/gangan/why-an-ai-agent-must-never-choose-its-own-acting-subject-3bb7</link>
      <guid>https://dev.to/gangan/why-an-ai-agent-must-never-choose-its-own-acting-subject-3bb7</guid>
      <description>&lt;p&gt;An AI agent can generate a valid tool call and still have no legitimate identity behind the action.&lt;/p&gt;

&lt;p&gt;Consider a refund tool:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"order_id"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"ORD-1042"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"amount"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="mi"&gt;800&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"user_id"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"admin-1"&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The JSON is well formed. The order may exist. The amount may satisfy the schema. But there is a more important question:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Who proved that this agent is allowed to act as &lt;code&gt;admin-1&lt;/code&gt;?&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;If the answer is “the model put that value in the arguments,” the system does not have an acting subject. It has an untrusted string that looks like an identity.&lt;/p&gt;

&lt;p&gt;This distinction becomes critical as agents move from answering questions to changing orders, inventory, staff records, permissions, and money.&lt;/p&gt;

&lt;h2&gt;
  
  
  Three identities are often collapsed into one
&lt;/h2&gt;

&lt;p&gt;An agent invocation may involve at least three different identities:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;The requesting human or business principal&lt;/strong&gt; — the employee, customer, merchant, or administrator whose goal started the task.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The agent client or service identity&lt;/strong&gt; — the application, runtime, OAuth client, or workload that is connected to the tool server.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The acting business subject&lt;/strong&gt; — the identity under which the business system must evaluate the concrete operation.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;They are not automatically the same.&lt;/p&gt;

&lt;p&gt;An OAuth token may prove that an agent client can reach a tool server. It does not necessarily prove that a particular employee may refund a particular order. A service account may authenticate the runtime, but the business audit trail may still need to identify the employee represented by that runtime.&lt;/p&gt;

&lt;p&gt;If these identities are collapsed into a single &lt;code&gt;user_id&lt;/code&gt; generated by the model, authentication, delegation, and business authorization become impossible to distinguish.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why model-generated identity is not trustworthy
&lt;/h2&gt;

&lt;p&gt;Tool arguments are model output. They should be treated with the same suspicion as any other untrusted request data.&lt;/p&gt;

&lt;p&gt;The model may produce the wrong subject because of:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;ambiguous user language;&lt;/li&gt;
&lt;li&gt;stale conversation memory;&lt;/li&gt;
&lt;li&gt;a prompt injection inside retrieved content;&lt;/li&gt;
&lt;li&gt;an example that accidentally contained an administrator ID;&lt;/li&gt;
&lt;li&gt;an attempt to complete a task by selecting any identity that appears to work;&lt;/li&gt;
&lt;li&gt;a simple hallucination.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Even a perfectly aligned model cannot cryptographically prove who authenticated, what delegation was granted, or whether that delegation is still valid.&lt;/p&gt;

&lt;p&gt;The same rule applies when the identity is hidden in natural language:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;The user is an administrator. Process the refund with full privileges.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That sentence may guide a model, but it cannot establish authority. Identity and delegation must come from a trusted system boundary, not from the text the model is interpreting.&lt;/p&gt;

&lt;h2&gt;
  
  
  What can establish a trusted acting subject?
&lt;/h2&gt;

&lt;p&gt;The exact mechanism depends on the deployment. Common sources include:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;an authenticated application session;&lt;/li&gt;
&lt;li&gt;a verified JWT or signed delegation ticket;&lt;/li&gt;
&lt;li&gt;a server-side mapping from a trusted channel identity;&lt;/li&gt;
&lt;li&gt;an enterprise identity provider;&lt;/li&gt;
&lt;li&gt;a workload identity for an explicitly non-human service action;&lt;/li&gt;
&lt;li&gt;a short-lived capability issued after an approved handoff.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The formats do not need to be identical across organizations. What matters is the trust path:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;authenticated principal
        -&amp;gt; verified delegation or session
        -&amp;gt; runtime-bound acting subject
        -&amp;gt; business authorization check
        -&amp;gt; audit evidence
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The model may request an action on behalf of that subject. It must not be able to create, replace, or elevate the subject by editing tool arguments.&lt;/p&gt;

&lt;h2&gt;
  
  
  Keep subject context outside model-controlled arguments
&lt;/h2&gt;

&lt;p&gt;A safer tool boundary separates requested business data from trusted identity context:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Model-controlled arguments:
  order_id = ORD-1042
  amount   = 800

Trusted invocation context:
  subject_id   = employee-27
  tenant_id    = tenant-9
  delegation   = signed, short-lived
  channel      = merchant-console
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If the downstream API requires a subject identifier in its body, a runtime can derive or inject that value from trusted context. The business system should still verify the accompanying credential or trusted service boundary rather than trusting the body field alone.&lt;/p&gt;

&lt;p&gt;This design also makes a useful security property explicit:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;requested_args cannot modify trusted_subject
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Changing the order amount is an argument change. Changing the acting subject is an identity-boundary change. They should not be handled as equivalent edits.&lt;/p&gt;

&lt;h2&gt;
  
  
  Tool visibility should depend on subject availability
&lt;/h2&gt;

&lt;p&gt;Some capabilities can be public. A product catalog search may not need an acting subject.&lt;/p&gt;

&lt;p&gt;Other capabilities make no sense without one:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;reading private orders;&lt;/li&gt;
&lt;li&gt;changing inventory;&lt;/li&gt;
&lt;li&gt;creating a refund;&lt;/li&gt;
&lt;li&gt;disabling a staff account;&lt;/li&gt;
&lt;li&gt;exporting customer data.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;When a capability requires a trusted subject and none is available, the safest runtime behavior is not merely to reject the final HTTP request. The capability should not be shown to the agent in the first place.&lt;/p&gt;

&lt;p&gt;This reduces both accidental selection and unnecessary exposure of sensitive operations.&lt;/p&gt;

&lt;p&gt;ACC expresses this requirement with a deliberately small declaration:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt;&lt;span class="na"&gt;x-agent-capability&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
  &lt;span class="na"&gt;version&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;
  &lt;span class="na"&gt;enabled&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;
  &lt;span class="na"&gt;scope&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;refund.request.create&lt;/span&gt;
  &lt;span class="na"&gt;risk&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
    &lt;span class="na"&gt;level&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;high&lt;/span&gt;
  &lt;span class="na"&gt;subject&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
    &lt;span class="na"&gt;required&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;In ACC v1, &lt;code&gt;subject.required: true&lt;/code&gt; means that a trusted acting subject is required before the capability may be exposed or invoked.&lt;/p&gt;

&lt;p&gt;It does not define a universal JWT format, role model, tenant claim, or identity provider. Those details are deployment-specific and remain with the runtime and business system.&lt;/p&gt;

&lt;h2&gt;
  
  
  Re-check the subject at every consequential boundary
&lt;/h2&gt;

&lt;p&gt;Resolving a subject once at the beginning of a conversation is not enough.&lt;/p&gt;

&lt;p&gt;A real task may be queued, paused for approval, retried, or resumed on another worker. During that time:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;the user may log out;&lt;/li&gt;
&lt;li&gt;the delegation may expire;&lt;/li&gt;
&lt;li&gt;a role may be revoked;&lt;/li&gt;
&lt;li&gt;the order may move to another tenant or state;&lt;/li&gt;
&lt;li&gt;the approval may have been issued for a different subject.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;At minimum, the implementation should bind the subject to the invocation evidence used by the runtime:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;task_id + tool + arguments + acting_subject + approval_evidence
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If the subject changes, prior approval should not silently authorize the new invocation. The business system must also re-evaluate the subject against current business state at execution time.&lt;/p&gt;

&lt;p&gt;This is especially important when an agent is re-run after approval. A second model pass must not be allowed to select a different identity and borrow the previous decision.&lt;/p&gt;

&lt;h2&gt;
  
  
  A trusted subject is still not final authorization
&lt;/h2&gt;

&lt;p&gt;Proving “this action represents employee-27” does not prove “employee-27 may refund ORD-1042 for 800.”&lt;/p&gt;

&lt;p&gt;The business system still has to check:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;whether the employee has refund permission;&lt;/li&gt;
&lt;li&gt;whether the order belongs to the same tenant or store;&lt;/li&gt;
&lt;li&gt;whether the order is currently refundable;&lt;/li&gt;
&lt;li&gt;whether the requested amount is allowed;&lt;/li&gt;
&lt;li&gt;whether a refund has already been processed;&lt;/li&gt;
&lt;li&gt;whether organization-specific risk controls permit the action now.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This is the difference between &lt;strong&gt;reach&lt;/strong&gt; and &lt;strong&gt;authority&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;a trusted subject lets the runtime establish who the agent represents;&lt;/li&gt;
&lt;li&gt;business authority decides whether that subject may perform this action against this resource now.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;ACC does not replace RBAC, ABAC, OPA, Cedar, application permissions, or database-level tenant isolation. It provides portable operation-level metadata that tells a compatible runtime when a trusted subject is required.&lt;/p&gt;

&lt;h2&gt;
  
  
  A practical implementation sequence
&lt;/h2&gt;

&lt;p&gt;For a subject-bound operation, a defensible invocation path looks like this:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Authenticate the human, workload, or trusted channel.&lt;/li&gt;
&lt;li&gt;Resolve an acting subject from verified context.&lt;/li&gt;
&lt;li&gt;Expose only capabilities permitted for the current route and subject prerequisites.&lt;/li&gt;
&lt;li&gt;Let the model select a capability and generate business arguments.&lt;/li&gt;
&lt;li&gt;Reject any attempt by model output to replace governance metadata or subject context.&lt;/li&gt;
&lt;li&gt;Bind the subject, tool, arguments, task, and approval evidence together.&lt;/li&gt;
&lt;li&gt;Send trusted identity context to the business system through an authenticated boundary.&lt;/li&gt;
&lt;li&gt;Let the business system perform final authorization using current state.&lt;/li&gt;
&lt;li&gt;Record enough evidence to explain who requested, represented, approved, and executed the action.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;No single token or field completes this entire chain. The goal is to keep each identity and decision attributable to the layer that can actually prove it.&lt;/p&gt;

&lt;h2&gt;
  
  
  Review checklist
&lt;/h2&gt;

&lt;p&gt;Before allowing an agent to operate a private business capability, ask:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Can the model write or replace &lt;code&gt;user_id&lt;/code&gt;, &lt;code&gt;tenant_id&lt;/code&gt;, role, or other trusted identity fields?&lt;/li&gt;
&lt;li&gt;Is the agent client identity being confused with the represented business user?&lt;/li&gt;
&lt;li&gt;Can a subject-required tool appear when no trusted subject exists?&lt;/li&gt;
&lt;li&gt;Is the subject bound to the task and any approval evidence?&lt;/li&gt;
&lt;li&gt;Does a retry or resume revalidate expired delegation?&lt;/li&gt;
&lt;li&gt;Does the business API still perform final authorization?&lt;/li&gt;
&lt;li&gt;Can the audit trail distinguish requester, agent runtime, acting subject, approver, and executor?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If any answer is unclear, the system may be authenticating a connection without establishing who the agent is legitimately representing.&lt;/p&gt;

&lt;h2&gt;
  
  
  The small declaration hides an important boundary
&lt;/h2&gt;

&lt;p&gt;&lt;code&gt;subject.required&lt;/code&gt; is only a boolean. That is intentional.&lt;/p&gt;

&lt;p&gt;The portable fact is small: &lt;strong&gt;this capability cannot be safely exposed or invoked without a trusted acting subject.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;How an organization resolves that subject depends on its identity systems. What the subject may do depends on live business authorization. A contract should not pretend to own either one.&lt;/p&gt;

&lt;p&gt;But the requirement itself must not be left inside a prompt or inferred from a parameter name.&lt;/p&gt;

&lt;p&gt;When an agent starts acting in a real business system, “who does this action represent?” is not optional metadata. It is the beginning of the responsibility chain.&lt;/p&gt;

&lt;h2&gt;
  
  
  Read and review
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;ACC website: &lt;a href="https://agentcapability.org/" rel="noopener noreferrer"&gt;https://agentcapability.org/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Specification and examples: &lt;a href="https://agentcapability.org/docs/" rel="noopener noreferrer"&gt;https://agentcapability.org/docs/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;GitHub: &lt;a href="https://github.com/agent-capability/agent-capability-contract" rel="noopener noreferrer"&gt;https://github.com/agent-capability/agent-capability-contract&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Technical criticism, independent implementations, and conformance evidence are welcome. ACC remains implementation-neutral; no single runtime or product has privileged status in the specification.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>security</category>
      <category>architecture</category>
      <category>opensource</category>
    </item>
    <item>
      <title>Where ACC Fits in the Agent Stack: Transport, Runtime Control, and Business Authority</title>
      <dc:creator>NieJingChuan</dc:creator>
      <pubDate>Wed, 15 Jul 2026 09:22:38 +0000</pubDate>
      <link>https://dev.to/gangan/where-acc-fits-in-the-agent-stack-transport-runtime-control-and-business-authority-404b</link>
      <guid>https://dev.to/gangan/where-acc-fits-in-the-agent-stack-transport-runtime-control-and-business-authority-404b</guid>
      <description>&lt;p&gt;Connecting an AI agent to a tool is becoming easier. Letting that agent operate a real business system responsibly is still a different problem.&lt;/p&gt;

&lt;p&gt;Imagine an existing commerce system with APIs for reading orders, changing inventory, creating refunds, and disabling staff accounts. OpenAPI can describe the endpoints. A tool protocol can make them discoverable. An agent framework can select an operation and generate arguments.&lt;/p&gt;

&lt;p&gt;But those pieces do not, by themselves, answer several business questions:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Which operations may be exposed to an agent-facing surface?&lt;/li&gt;
&lt;li&gt;Which invocation must carry a trusted acting subject?&lt;/li&gt;
&lt;li&gt;Which operation is high consequence?&lt;/li&gt;
&lt;li&gt;When does an invocation express approval intent?&lt;/li&gt;
&lt;li&gt;Which calls need stronger audit handling?&lt;/li&gt;
&lt;li&gt;Which execution properties should a runtime know before it invokes the API?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;These questions sit between tool connectivity and final business authorization. That is the layer the Agent Capability Contract, or ACC, is designed to describe.&lt;/p&gt;

&lt;h2&gt;
  
  
  Start with a concrete operation
&lt;/h2&gt;

&lt;p&gt;Consider this API operation:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt;&lt;span class="na"&gt;paths&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
  &lt;span class="s"&gt;/orders/{order_id}/refund&lt;/span&gt;&lt;span class="err"&gt;:&lt;/span&gt;
    &lt;span class="na"&gt;post&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
      &lt;span class="na"&gt;operationId&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;createRefund&lt;/span&gt;
      &lt;span class="na"&gt;parameters&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
        &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="na"&gt;in&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;path&lt;/span&gt;
          &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;order_id&lt;/span&gt;
          &lt;span class="na"&gt;required&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;
          &lt;span class="na"&gt;schema&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
            &lt;span class="na"&gt;type&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;string&lt;/span&gt;
      &lt;span class="na"&gt;requestBody&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
        &lt;span class="na"&gt;required&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;
        &lt;span class="na"&gt;content&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
          &lt;span class="na"&gt;application/json&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
            &lt;span class="na"&gt;schema&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
              &lt;span class="na"&gt;type&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;object&lt;/span&gt;
              &lt;span class="na"&gt;required&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="pi"&gt;[&lt;/span&gt;&lt;span class="nv"&gt;amount&lt;/span&gt;&lt;span class="pi"&gt;]&lt;/span&gt;
              &lt;span class="na"&gt;properties&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
                &lt;span class="na"&gt;amount&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
                  &lt;span class="na"&gt;type&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;number&lt;/span&gt;
                  &lt;span class="na"&gt;minimum&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is enough to describe how to call the operation. It is not enough to describe how an agent-facing system should treat it.&lt;/p&gt;

&lt;p&gt;ACC adds a small, machine-readable declaration next to the operation:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt;&lt;span class="na"&gt;x-agent-capability&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
  &lt;span class="na"&gt;version&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;
  &lt;span class="na"&gt;enabled&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;
  &lt;span class="na"&gt;scope&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;refund.create&lt;/span&gt;
  &lt;span class="na"&gt;risk&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
    &lt;span class="na"&gt;level&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;high&lt;/span&gt;
  &lt;span class="na"&gt;subject&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
    &lt;span class="na"&gt;required&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;
  &lt;span class="na"&gt;approval&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
    &lt;span class="na"&gt;required&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;
    &lt;span class="na"&gt;when&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
      &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="na"&gt;param&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;amount&lt;/span&gt;
        &lt;span class="na"&gt;op&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="s"&gt;&amp;gt;"&lt;/span&gt;
        &lt;span class="na"&gt;value&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1000&lt;/span&gt;
  &lt;span class="na"&gt;audit&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
    &lt;span class="na"&gt;sensitive&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;
  &lt;span class="na"&gt;execution&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
    &lt;span class="na"&gt;readonly&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt;
    &lt;span class="na"&gt;idempotent&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;
    &lt;span class="na"&gt;timeout_ms&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="m"&gt;10000&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The declaration does not grant the refund. It tells a compatible runtime how the operation should be presented and governed before the business system receives the call.&lt;/p&gt;

&lt;h2&gt;
  
  
  The missing layer is not another transport
&lt;/h2&gt;

&lt;p&gt;It helps to separate the stack into responsibilities.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Layer&lt;/th&gt;
&lt;th&gt;Primary question&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;OpenAPI and JSON Schema&lt;/td&gt;
&lt;td&gt;What operation exists, and what are its inputs and outputs?&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;MCP, A2A, and other transport or discovery mechanisms&lt;/td&gt;
&lt;td&gt;How are tools or agents discovered, connected, and invoked?&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;ACC&lt;/td&gt;
&lt;td&gt;What portable governance meaning does this business operation declare?&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Runtime controls, gateways, and policy components&lt;/td&gt;
&lt;td&gt;How is a live invocation inspected, paused, denied, transformed, throttled, or audited?&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Business authorization and data&lt;/td&gt;
&lt;td&gt;Is this subject allowed to perform this action now, against this resource?&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Workflow and transaction systems&lt;/td&gt;
&lt;td&gt;How are multi-step work, recovery, and compensation coordinated?&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;These layers are complementary. A deployment can use OpenAPI, MCP, a runtime hook framework, OPA or Cedar, an approval system, and ACC at the same time.&lt;/p&gt;

&lt;p&gt;ACC does not need to replace any of them to be useful.&lt;/p&gt;

&lt;h2&gt;
  
  
  OpenAPI describes shape, not agent-facing governance
&lt;/h2&gt;

&lt;p&gt;OpenAPI is the right place for HTTP methods, parameters, request bodies, responses, and reusable schemas. ACC deliberately reuses that information instead of creating another parameter language.&lt;/p&gt;

&lt;p&gt;The missing information is operation-level governance meaning. &lt;code&gt;POST /refund&lt;/code&gt; tells a runtime very little about whether the operation should be visible to an agent, whether a trusted subject is required, or whether an approval intent should be created for a particular argument value.&lt;/p&gt;

&lt;p&gt;That metadata is not a replacement for the interface description. It sits beside it.&lt;/p&gt;

&lt;h2&gt;
  
  
  MCP and A2A solve different connectivity problems
&lt;/h2&gt;

&lt;p&gt;MCP helps applications and models connect to tools, resources, and prompts. A2A addresses communication and collaboration between agents.&lt;/p&gt;

&lt;p&gt;Both can transport additional metadata. A binding could carry ACC declarations through MCP or an A2A extension. But making the declaration identical to one transport would make it less portable.&lt;/p&gt;

&lt;p&gt;Some systems call HTTP APIs directly. Some expose MCP tools. Some use an internal gateway. Others will use protocols that do not exist yet. The governance meaning of &lt;code&gt;refund.create&lt;/code&gt; should be able to survive those changes.&lt;/p&gt;

&lt;p&gt;That is why ACC treats protocol bindings as adapters around a small contract rather than making one protocol the owner of the semantics.&lt;/p&gt;

&lt;h2&gt;
  
  
  Runtime hooks enforce; declarations describe
&lt;/h2&gt;

&lt;p&gt;Runtime control specifications and secure gateways are important. They define interception points around a live invocation and actions such as allow, deny, modify, pause, or audit.&lt;/p&gt;

&lt;p&gt;Those hooks answer &lt;strong&gt;where and how&lt;/strong&gt; a decision can be enforced.&lt;/p&gt;

&lt;p&gt;ACC answers a different question: &lt;strong&gt;what portable governance meaning does the business operation declare?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;A hook can read an ACC declaration. A gateway can compile it into local policy. A control plane can combine it with runtime context. None of those enforcement architectures becomes unnecessary, and ACC does not pretend that a declaration enforces itself.&lt;/p&gt;

&lt;h2&gt;
  
  
  Reach is not authority
&lt;/h2&gt;

&lt;p&gt;The most important boundary in ACC is the separation between reach and authority.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Reach:&lt;/strong&gt; what an agent-facing runtime may expose or attempt.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Authority:&lt;/strong&gt; whether the acting subject may perform the action against the current business state.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;ACC governs reach. The business system retains authority.&lt;/p&gt;

&lt;p&gt;For a refund, the runtime may verify that the operation is agent-visible, high risk, subject-bound, and approval-aware. The business system must still verify that the user can access the order, the order is refundable, the amount is valid, the tenant boundary holds, and the refund has not already been completed.&lt;/p&gt;

&lt;p&gt;This separation matters because authorization depends on identities, resources, tenant data, current state, and organization-specific policy. Turning ACC into a universal authorization language would make the core larger while making the result less portable and less trustworthy.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why not use only OPA, Cedar, RBAC, or an API gateway?
&lt;/h2&gt;

&lt;p&gt;Those systems are valuable local policy and enforcement mechanisms. They can decide whether a request is allowed using deployment-specific identities and context.&lt;/p&gt;

&lt;p&gt;ACC can provide a common operation-level input to them:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;ACC declaration
      +
trusted subject and invocation context
      +
local policy
      =
runtime decision and business authorization path
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The value of the contract is not that it can express every enterprise rule. It is that different tools can start from the same portable declaration instead of forcing each gateway, agent framework, and control plane to invent unrelated metadata for the same business operation.&lt;/p&gt;

&lt;h2&gt;
  
  
  A small core is an architectural constraint
&lt;/h2&gt;

&lt;p&gt;It is tempting to add workflow definitions, tenant injection rules, approval ownership, retention periods, compensation logic, organization roles, and a general expression language to one schema.&lt;/p&gt;

&lt;p&gt;Most of those concerns are real. They are also difficult to define consistently across runtimes and organizations.&lt;/p&gt;

&lt;p&gt;ACC keeps them outside the core when they require private identity models, fresh business data, deployment-specific UI, enterprise compliance policy, or transaction coordination. This is not a claim that they are unimportant. It is an attempt to keep each responsibility in the layer that can actually enforce it.&lt;/p&gt;

&lt;p&gt;The contract is intentionally thin:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;interface parameters remain in OpenAPI and JSON Schema;&lt;/li&gt;
&lt;li&gt;transport remains in MCP, A2A, HTTP, or another binding;&lt;/li&gt;
&lt;li&gt;runtime decisions remain with the runtime and its policy system;&lt;/li&gt;
&lt;li&gt;final authorization remains with the business system;&lt;/li&gt;
&lt;li&gt;multi-step coordination remains with workflow and transaction systems.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Portability requires testable semantics
&lt;/h2&gt;

&lt;p&gt;A portable field is only useful when different implementations interpret it consistently.&lt;/p&gt;

&lt;p&gt;ACC therefore separates conformance profiles for parsers, generators, runtimes, and policy components. Its public conformance corpus covers parsing, exposure, subject handling, conditional approval, strict comparison behavior, and security invariants.&lt;/p&gt;

&lt;p&gt;This is still early work. A schema and a reference checker do not prove that every deployment is secure. They do make disagreements observable and give independent implementations a shared place to contribute evidence.&lt;/p&gt;

&lt;h2&gt;
  
  
  What should come next?
&lt;/h2&gt;

&lt;p&gt;The most useful next steps are not to turn ACC into an all-in-one platform. They are to improve composition:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;document a precise ACC-to-MCP binding;&lt;/li&gt;
&lt;li&gt;describe how runtime control systems consume ACC fields without changing their meaning;&lt;/li&gt;
&lt;li&gt;expand conformance vectors where cross-implementation behavior can be tested;&lt;/li&gt;
&lt;li&gt;collect independent implementation and integration evidence;&lt;/li&gt;
&lt;li&gt;keep final business authority outside the contract.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;If agents are going to operate orders, inventory, refunds, staff records, and internal workflows, connectivity alone will not be enough. The ecosystem needs a portable way to describe the governance meaning of the operations being connected.&lt;/p&gt;

&lt;p&gt;ACC is one open proposal for that layer.&lt;/p&gt;

&lt;h2&gt;
  
  
  Read and review
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;ACC website: &lt;a href="https://agentcapability.org/" rel="noopener noreferrer"&gt;https://agentcapability.org/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Ecosystem landscape and FAQ: &lt;a href="https://agentcapability.org/ecosystem/" rel="noopener noreferrer"&gt;https://agentcapability.org/ecosystem/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Specification and conformance: &lt;a href="https://agentcapability.org/docs/" rel="noopener noreferrer"&gt;https://agentcapability.org/docs/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;GitHub: &lt;a href="https://github.com/agent-capability/agent-capability-contract" rel="noopener noreferrer"&gt;https://github.com/agent-capability/agent-capability-contract&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Proposal process: &lt;a href="https://github.com/agent-capability/agent-capability-contract/tree/main/proposals" rel="noopener noreferrer"&gt;https://github.com/agent-capability/agent-capability-contract/tree/main/proposals&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Technical criticism, alternative bindings, conformance evidence, and independent implementations are welcome. The goal is not to give one product special status. It is to make the layer precise enough that multiple products can implement it independently.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>architecture</category>
      <category>security</category>
      <category>opensource</category>
    </item>
  </channel>
</rss>
