function createWithClient createWithClient<Client>(getClient: () => Client | null | Promise<Client | null>) Create a withClient helper that runs an operation with a lazily-resolved client. Returns null if the client is not available or the operation fails. Type Parameters Client Parameters getClient: () => Client | null | Promise<Client | null> Return Type