vigiles API reference
    Preparing search index...

    Interface OutputContract<Ok, Err>

    A subagent's typed result contract: the shape it must return on success (ok) and on failure (err). Rich on both tracks — an error is structured detail, not a bare pass/fail bit. Compiles into the worker's system prompt (the vigiles:ok / vigiles:err block it must emit) and is the schema the parseAgentResult parser + the assertAgentOk/Err test helpers validate.

    Generic over its ok/err field shapes so a typed value REMEMBERS them at the type level (the basis of typed composition — see pipe). The default type parameters widen to the historical erased Shape, so an OutputContract named with no arguments behaves exactly as before — backwards-compatible.

    interface OutputContract<Ok extends Shape = Shape, Err extends Shape = Shape> {
        _ref: "output";
        err: Err;
        ok: Ok;
    }

    Type Parameters

    Index

    Properties

    Properties

    _ref: "output"
    err: Err
    ok: Ok