type alias ClientRunner

Run an operation with the lazily-resolved client. Returns null when the client is unconfigured or the operation fails (unless the error should propagate). The named type keeps the contract visible to callers of the widely-used stripeClientRuntime.run so a signature drift fails at the definition instead of leaking to callers.

Type Parameters

Client

Definition

<T>(
fn: (value: Client) => Promise<T>,
errorCode: ErrorCodeType,
) => Promise<T | null>

Usage

import { type ClientRunner } from "doc.ts";