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

    Interface DurableSecretOperationOptions<T>

    Full operation contract for safely executing a durable-secret-producing call.

    interface DurableSecretOperationOptions<T> {
        create: () => Promise<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;
        secretSink: ActiveSecretSinkConfig;
        toolName: string;
    }

    Type Parameters

    • T

    Hierarchy

    Index
    create: () => Promise<T>

    Provider operation that creates the durable secret.

    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.

    Active sink configuration.

    toolName: string

    MCP tool name producing the durable secret.