///
import { EventEmitter } from 'node:events';
import { type PermissionTypeValue, type PermissionStatusValue, type StartCaptureSessionClientConfig, type CaptureClientOptions, type TrackTypeValue } from './types';
import { Channels, type ChannelClient } from './channel';
/**
* CaptureClient provides client-side recording capabilities using the native binary
*
* @example
* ```typescript
* import { CaptureClient } from 'videodb/capture';
*
* const client = new CaptureClient({ sessionToken: token });
*
* // Request permissions
* await client.requestPermission('microphone');
* await client.requestPermission('screen_capture');
*
* // List available channels
* const channels = await client.listChannels();
*
* // Start capture session (sessionId from backend CaptureSession)
* await client.startSession({
* sessionId: 'ss-xxx', // Required: from CaptureSession.id
* channels: [
* { channelId: 'mic:default', type: 'audio', store: true },
* { channelId: 'display:1', type: 'video', store: true },
* ],
* });
*
* // Stop capture
* await client.stopSession();
*
* // Cleanup
* await client.shutdown();
* ```
*/
export declare class CaptureClient extends EventEmitter implements ChannelClient {
private sessionToken;
private apiUrl;
private binaryManager;
private isInitialized;
private currentSessionId;
constructor(options: CaptureClientOptions);
/**
* Initialize the capture client (starts the binary)
*/
private ensureInitialized;
/**
* Request a system permission
* @param kind - The type of permission to request
* @returns The permission status
*/
requestPermission(kind: PermissionTypeValue): Promise;
/**
* List available capture channels grouped by type
*
* Returns a Channels object with mics, displays, and systemAudio properties.
* Each property is a ChannelList with a `.default` property to get the first channel.
*
* @returns Channels object with grouped channels that support pause/resume
*
* @example
* ```typescript
* const channels = await client.listChannels();
*
* // Access default channels
* const defaultMic = channels.mics.default;
* const defaultDisplay = channels.displays.default;
*
* // Pause/resume individual channels
* await channels.mics.default?.pause();
* await channels.mics.default?.resume();
*
* // Iterate over all mics
* for (const mic of channels.mics) {
* console.log(mic.name);
* }
* ```
*/
listChannels(): Promise;
/**
* Start capture session
* @param config - Capture session configuration (sessionId is required)
*/
startSession(config: StartCaptureSessionClientConfig): Promise;
/**
* Stop the current capture session
*/
stopSession(): Promise;
/**
* Pause specific tracks
* @param tracks - Array of track types to pause
*/
pauseTracks(tracks: TrackTypeValue[]): Promise;
/**
* Resume specific tracks
* @param tracks - Array of track types to resume
*/
resumeTracks(tracks: TrackTypeValue[]): Promise;
/**
* Gracefully shutdown the capture client
*/
shutdown(): Promise;
/**
* Check if the capture client is initialized
*/
get initialized(): boolean;
/**
* Check if a capture is currently active
*/
get isCapturing(): boolean;
}