import { MessageChunk } from "@axiom-lattice/protocols";
import { AgentState, ClientConfig, ResumeStreamOptions, RunOptions } from "./types";
import { AbstractClient } from "./abstract-client";
/**
 * Web client class for interacting with the Axiom Lattice Agent Service API
 */
export declare class Client extends AbstractClient {
    private headers;
    /**
     * Creates a new Client instance
     * @param config - Configuration options for the client
     */
    constructor(config: ClientConfig);
    /**
     * Helper method to handle fetch responses and errors
     * @private
     */
    private handleResponse;
    /**
     * Helper method to make fetch requests
     * @private
     */
    private fetchWithTimeout;
    private static workspaceHeaders;
    /**
     * Set tenant ID for multi-tenant environments
     * @param tenantId - Tenant identifier
     */
    setTenantId(tenantId: string): void;
    /**
     * Set workspace and project headers for API requests (static)
     * @param workspaceId - Workspace identifier
     * @param projectId - Project identifier
     */
    static setWorkspaceContext(workspaceId?: string, projectId?: string): void;
    /**
     * Get current workspace headers
     */
    static getWorkspaceHeaders(): Record<string, string>;
    /**
     * Creates a new instance of the client with the given configuration
     * @param config - Configuration options for the client
     * @returns A new Client instance
     */
    protected createInstance(config: ClientConfig): AbstractClient;
    /**
     * Implementation of the abstract makeRequest method for web clients
     * @param url - The URL to make the request to
     * @param options - Request options
     * @returns A promise that resolves to the response data
     */
    protected makeRequest<T>(url: string, options?: {
        method?: string;
        body?: any;
        headers?: Record<string, string>;
    }): Promise<T>;
    /**
     * Implementation of the abstract streamRequest method for web clients
     */
    protected streamRequest(options: RunOptions, onEvent: (event: MessageChunk) => void, onComplete?: (state?: AgentState) => void, onError?: (error: Error) => void): () => void;
    /**
     * Resume streaming from a known position
     * @param options - Options for resuming the stream
     * @param onEvent - Callback function that receives stream events
     * @param onComplete - Optional callback function called when streaming completes
     * @param onError - Optional callback function called when an error occurs
     * @returns A function that can be called to stop the stream
     */
    resumeStream(options: ResumeStreamOptions, onEvent: (event: MessageChunk) => void, onComplete?: () => void, onError?: (error: Error) => void): () => void;
    /**
     * Stream run results
     * @param options - Options for streaming run results
     * @param onEvent - Callback function that receives stream events
     * @param onComplete - Optional callback function called when streaming completes
     * @param onError - Optional callback function called when an error occurs
     * @returns A function that can be called to stop the stream
     */
    /**
     * Get all headers including workspace context
     * @private
     */
    protected getAllHeaders(): Record<string, string>;
    private streamRun;
}
//# sourceMappingURL=client.d.ts.map