/**
 * Plugin source type definitions
 */
import type { PluginInfo } from './plugin.js';
/**
 * Supported source types
 */
export type SourceType = 'spigot' | 'modrinth' | 'github' | 'bukkit' | 'web' | 'jenkins' | 'ninsys' | 'hangar' | 'geysermc';
/**
 * Configuration for a plugin source
 */
export interface SourceConfig {
    id: string;
    name: string;
    type: SourceType;
    url: string;
    enabled?: boolean;
    checkIntervalSeconds?: number;
    priority?: number;
    apiKey?: string;
    username?: string;
    password?: string;
    cacheEnabled?: boolean;
    cacheExpirySeconds?: number;
    extraParams?: Record<string, string>;
}
/**
 * Sources configuration file structure
 */
export interface SourcesConfig {
    version: string;
    description?: string;
    sources: SourceConfig[];
}
/**
 * Interface for plugin source implementations
 */
export interface IPluginSource {
    readonly id: string;
    readonly name: string;
    readonly type: SourceType;
    enabled: boolean;
    priority: number;
    /**
     * Get plugin information by identifier
     * @param identifier - Plugin identifier (format varies by source)
     * @returns Plugin info or null if not found
     */
    getPluginInfo(identifier: string): Promise<PluginInfo | null>;
    /**
     * Search for plugins
     * @param query - Search query
     * @param limit - Maximum results
     * @returns Array of matching plugins
     */
    searchPlugins(query: string, limit?: number): Promise<PluginInfo[]>;
    /**
     * Get latest version for a plugin
     * @param identifier - Plugin identifier
     * @returns Version string or null
     */
    getLatestVersion(identifier: string): Promise<string | null>;
    /**
     * Check if source supports a Minecraft version
     * @param mcVersion - Minecraft version string
     * @returns Whether version is supported
     */
    supportsMinecraftVersion(mcVersion: string): Promise<boolean>;
    /**
     * Clear the source's internal cache
     * Useful when troubleshooting stale cached results
     */
    clearCache(): void;
}
/**
 * Options for source requests
 */
export interface SourceRequestOptions {
    timeout?: number;
    mcVersion?: string;
    useCache?: boolean;
}
/**
 * Cached response entry
 */
export interface CacheEntry<T> {
    data: T;
    timestamp: number;
    expiresAt: number;
}
//# sourceMappingURL=source.d.ts.map