/** * ApiPresetsService * * Service layer for API presets queries. * Provides O(1) lookups for presets by endpoint. * * @example * import { ApiPresetsService } from './api-presets.service' * * // Get presets for an endpoint * const presets = ApiPresetsService.getByEndpoint('/api/v1/customers') * * // Get presets filtered by method * const getPresets = ApiPresetsService.getByEndpointAndMethod('/api/v1/customers', 'GET') */ import { type ApiEndpointPresets, type ApiPreset } from '@nextsparkjs/registries/api-presets-registry'; export type { ApiEndpointPresets, ApiPreset }; /** * ApiPresetsService * * Service layer for API presets queries. * All methods are static for consistency with other services. */ export declare class ApiPresetsService { /** * Get all presets for an endpoint * * @param endpoint - The endpoint path (e.g., '/api/v1/customers') * @returns Endpoint presets config or undefined if not found * * @example * const config = ApiPresetsService.getByEndpoint('/api/v1/customers') * if (config) { * console.log(`Found ${config.presets.length} presets`) * } */ static getByEndpoint(endpoint: string): ApiEndpointPresets | undefined; /** * Get presets filtered by HTTP method * * @param endpoint - The endpoint path * @param method - The HTTP method (GET, POST, etc.) * @returns Array of presets for that method * * @example * const getPresets = ApiPresetsService.getByEndpointAndMethod('/api/v1/customers', 'GET') */ static getByEndpointAndMethod(endpoint: string, method: string): ApiPreset[]; /** * Get all endpoint presets configurations * * @returns Array of all endpoint preset configs */ static getAll(): ApiEndpointPresets[]; /** * Check if an endpoint has presets defined * * @param endpoint - The endpoint path * @returns True if presets exist for this endpoint */ static hasPresets(endpoint: string): boolean; /** * Get registry metadata * * @returns Object with totalEndpoints, totalPresets, generatedAt, themeName */ static getMeta(): any; /** * Get total count of presets * * @returns Total number of presets across all endpoints */ static getTotalPresets(): number; /** * Get total count of endpoints with presets * * @returns Total number of endpoints that have presets defined */ static getTotalEndpoints(): number; /** * Search presets by tag * * @param tag - The tag to search for * @returns Array of presets that have this tag */ static getByTag(tag: string): ApiPreset[]; /** * Get all unique tags across all presets * * @returns Array of unique tag strings */ static getAllTags(): string[]; } //# sourceMappingURL=api-presets.service.d.ts.map