1111//! - callers see structured capability outcomes instead of lower substrate
1212//! handles;
1313//! - approval/auth/resource waits are suspension states, not errors;
14- //! - request origin and capability projection metadata never grant or bypass
15- //! authority.
14+ //! - caller/workflow origin taxonomy is intentionally kept outside this lower
15+ //! facade; authority remains in `ExecutionContext` and projection selection
16+ //! remains explicit surface metadata.
1617
1718use async_trait:: async_trait;
1819use ironclaw_host_api:: {
@@ -152,20 +153,6 @@ impl fmt::Display for CapabilitySurfaceVersion {
152153 }
153154}
154155
155- /// Product-owned workflow origin for audit/correlation context.
156- ///
157- /// This is not authority and must never grant or bypass authority. Authority
158- /// remains exclusively in `ExecutionContext`, principals, grants, leases, and
159- /// policy. Projection differences belong in [`CapabilitySurfaceKind`]. Runtime
160- /// adapters are callees of `HostRuntime`, not top-level caller/origin values.
161- #[ derive( Debug , Clone , Copy , PartialEq , Eq , Hash ) ]
162- #[ non_exhaustive]
163- pub enum RuntimeRequestOrigin {
164- TurnCoordinator ,
165- MissionService ,
166- SystemService ,
167- }
168-
169156/// Which host-filtered surface a caller is asking to render.
170157#[ derive( Debug , Clone , Copy , PartialEq , Eq , Hash ) ]
171158#[ non_exhaustive]
@@ -176,6 +163,12 @@ pub enum CapabilitySurfaceKind {
176163}
177164
178165/// Request to invoke one capability through the composed host runtime.
166+ ///
167+ /// Caller/workflow origin is intentionally not part of this lower contract.
168+ /// Host runtime authorization must be derived from [`ExecutionContext`],
169+ /// principals, grants, leases, and policy; upper workflow services can attach
170+ /// audit labels outside this facade when they need product-specific origin
171+ /// vocabulary.
179172#[ derive( Debug , Clone , PartialEq ) ]
180173pub struct RuntimeCapabilityRequest {
181174 pub context : ExecutionContext ,
@@ -187,8 +180,6 @@ pub struct RuntimeCapabilityRequest {
187180 /// and must not trust caller estimates as binding limits or actual usage.
188181 pub estimate : ResourceEstimate ,
189182 pub input : Value ,
190- /// Product workflow origin for audit/correlation only.
191- pub request_origin : RuntimeRequestOrigin ,
192183 pub idempotency_key : Option < IdempotencyKey > ,
193184}
194185
@@ -197,8 +188,8 @@ pub struct RuntimeCapabilityRequest {
197188pub struct VisibleCapabilityRequest {
198189 pub scope : ResourceScope ,
199190 pub correlation_id : CorrelationId ,
200- /// Product workflow origin for audit/correlation only.
201- pub request_origin : RuntimeRequestOrigin ,
191+ /// Projection surface selection only; this is not authority and must not
192+ /// grant or bypass authorization.
202193 pub surface_kind : CapabilitySurfaceKind ,
203194}
204195
0 commit comments