@nevermined-io/payments
    Preparing search index...

    Interface MppSettlementOutcomeUnknown

    What paymentMiddleware's onAfterSettle hook receives as its third argument when settlement raised MppSettlementOutcomeUnknownError. That parameter's declared type is unknown (shared with the x402 hook of the same name — out of scope to narrow here), so nothing stops a consumer from casting straight to MppSettleResult and silently reading undefined for creditsRedeemed on this branch. Exporting this shape gives a consumer something concrete to check for instead — e.g. if ((result as MppSettlementOutcomeUnknown).outcome === 'unknown') — and documents, at the type level, that the branch exists at all.

    interface MppSettlementOutcomeUnknown {
        outcome: "unknown";
        reason: string;
    }
    Index

    Properties

    Properties

    outcome: "unknown"
    reason: string