@datastax/langflow-client
Version:
A JavaScript client for the Langflow API
17 lines (16 loc) • 793 B
TypeScript
import { LangflowClient } from "./index.js";
import { FlowResponse } from "./flow_response.js";
import { UploadResponse } from "./upload_response.js";
import { Tweaks, Tweak, FlowRequestOptions, StreamEvent } from "./types.js";
export declare class Flow {
client: LangflowClient;
id: string;
tweaks: Tweaks;
constructor(client: LangflowClient, flowId: string, tweaks?: Tweaks);
tweak(key: string, tweak: Tweak): Flow;
run(input_value: string, options?: Partial<Omit<FlowRequestOptions, "input_value">>): Promise<FlowResponse>;
stream(input_value: string, options?: Partial<Omit<FlowRequestOptions, "input_value">>): Promise<ReadableStream<StreamEvent>>;
uploadFile(file: File | Blob, options?: {
signal?: AbortSignal;
}): Promise<UploadResponse>;
}