@backblaze-labs/b2-mcp
    Preparing search index...

    Interface DurableSecretResponseOptions<T>

    Response projection hooks for durable-secret-producing operations.

    interface DurableSecretResponseOptions<T> {
        diagnostics?: (result: T) => Record<string, unknown>;
        idempotency: DurableSecretIdempotency;
        projectInline: (result: T, warning: string) => unknown;
        projectRedacted: (result: T, pointer: SecretSinkPointer) => unknown;
        recoverAfterSinkFailure?: (result: T, err: unknown) => unknown;
        result: T;
        secretSink: ActiveSecretSinkConfig;
        toolName: string;
    }

    Type Parameters

    • T
    Index
    diagnostics?: (result: T) => Record<string, unknown>

    Non-secret diagnostics for critical logs after sink failures.

    Idempotency metadata for replay protection.

    projectInline: (result: T, warning: string) => unknown

    Projection used when inline mode deliberately returns the secret.

    projectRedacted: (result: T, pointer: SecretSinkPointer) => unknown

    Pure projection used when a file sink stores the secret out of band.

    File mode may invoke this once with a synthetic preflight pointer before the ledger write and again with the committed pointer after the write. Implementations must not perform side effects and must tolerate pointer records that are not durable sink entries.

    recoverAfterSinkFailure?: (result: T, err: unknown) => unknown

    Optional provider-side cleanup when sink storage fails after creation.

    result: T

    Secret-bearing provider result.

    Active sink configuration.

    toolName: string

    MCP tool name producing the durable secret.