Skip to main content

Crate khive_request

Crate khive_request 

Source
Expand description

khive-request — transport-agnostic DSL parser for verb-dispatch requests.

Re-exports§

pub use atomic::check_atomic_admissible;
pub use atomic::AtomicRejection;

Modules§

atomic
Pure ADR-099 atomic-admissibility preflight over parsed operations.

Structs§

ParsedOp
One parsed tool name and its deterministically ordered named arguments.
ParsedRequest
Parsed operations in input order plus their execution mode.
TypedJsonOp
One already-decoded JSON operation for a bounded trusted transport.
UnitKeyConflict
One cross-unit static write-key conflict: leaf (inside the unit this entry is filed under) claims the same statically knowable write key as other_leaf, which belongs to a different unit, other_unit.

Enums§

ArgValue
A concrete JSON argument or chain-time $prev expression.
DslError
Request syntax or preflight error surfaced as MCP invalid_params.
ExecutionMode
Execution mode: Single (one op), Parallel ([...]), or Chain (op | op).
PrevFailure
Explains why a $prev path failed to resolve, for error-message construction. Distinguishes three mistakes that a single generic “not found” message conflates:

Constants§

MAX_OPS
Maximum operations in a batch or chain.
MAX_OPS_INPUT_LEN
Maximum raw ops byte length, checked before parsing.
NESTING_DEPTH_LIMIT
Maximum array/object nesting in function and JSON forms.
RESERVED_ENVELOPE_ARGS
Names reserved at the request-envelope level; rejected if they appear inside verb args. Argument names owned by the outer request envelope rather than verb handlers.

Functions§

parse_request
Parses function-call, batch, chain, or JSON request syntax.
parse_typed_json_batch
Validates an already-decoded JSON batch without reapplying the raw DSL byte cap.
plan_request
Parses a request and describes its stages using a verb-to-pack catalog.
unit_write_key_conflicts
Finds every statically knowable write-key collision between different units of a bracketed batch of chains (ADR-016 Amendment 2).
value_nesting_within_limit
Returns whether every array/object in value is at most max_depth deep.
write_keys_for_op_pub
Extracts statically knowable, substrate-prefixed write-conflict keys for op.