import type { XtreamAuthResponse, XtreamCategory, XtreamChannel, XtreamVOD, XtreamSeries, XtreamSeriesInfo, Channel, Movie, Series } from '../types'; /** * Xtream Codes API Client * Handles authentication and fetching channels from Xtream Codes providers */ export declare class XtreamClient { private baseUrl; private originalBaseUrl; private username; private password; private authInfo?; private proxyUrl?; private timeout; private preferredProtocol?; constructor(serverUrl: string, username: string, password: string, proxyUrl?: string, timeout?: number); /** * Make a fetch request with timeout and proper headers * Configured for React Native compatibility */ private fetchWithTimeout; /** * Make a request and parse JSON response * Uses fetch for both HTTP and HTTPS (better iOS Simulator compatibility) * Tries both HTTP and HTTPS if the initial request fails */ private makeRequest; /** * Build the full URL for an API request * Uses proxy if available, otherwise direct URL * If we've determined a preferred protocol, use it */ private buildRequestUrl; /** * Authenticate with Xtream Codes server * @returns Authentication response with user and server info */ authenticate(): Promise; /** * Get live stream categories * @returns Array of categories */ getCategories(): Promise; /** * Get live streams (channels) * @param categoryId - Optional category ID to filter by * @returns Array of Xtream channels */ getLiveStreams(categoryId?: string): Promise; /** * Get EPG URL for this Xtream provider * Xtream Codes API typically provides EPG at: /xmltv.php?username=...&password=... * @returns EPG URL if available */ getEPGUrl(): string; /** * Get all channels in our Channel format * @param providerId - ID of the provider * @returns Array of Channel objects */ getChannels(providerId: string): Promise; /** * Get VOD categories * @returns Array of VOD categories */ getVODCategories(): Promise; /** * Get VOD (movies) * @param categoryId - Optional category ID to filter by * @returns Array of VOD items */ getVOD(categoryId?: string): Promise; /** * Get all movies in our Movie format * @param providerId - ID of the provider * @returns Array of Movie objects */ getMovies(providerId: string): Promise; /** * Get Series categories * @returns Array of Series categories */ getSeriesCategories(): Promise; /** * Get Series (TV Shows) * @param categoryId - Optional category ID to filter by * @returns Array of Series */ getSeriesList(categoryId?: string): Promise; /** * Get all series in our Series format * @param providerId - ID of the provider * @returns Array of Series objects */ getSeries(providerId: string): Promise; /** * Get series info with episodes * @param seriesId - Series ID * @returns Series info with episodes */ getSeriesInfo(seriesId: string): Promise; /** * Test connection to Xtream server * @returns true if connection successful, false otherwise */ testConnection(): Promise; /** * Get server info (requires authentication) * @returns Server info object */ getServerInfo(): import("..").XtreamServerInfo; /** * Get user info (requires authentication) * @returns User info object */ getUserInfo(): import("..").XtreamUserInfo; /** * Get full auth response (requires authentication) * @returns Full authentication response with user and server info */ getAuthInfo(): XtreamAuthResponse; } //# sourceMappingURL=xtream.d.ts.map