import { apiClient } from './client';
import type { MitreTechnique } from './types';

export async function searchMitreTechniques(query: string): Promise<MitreTechnique[]> {
  const { data } = await apiClient.get<MitreTechnique[]>('/mitre/techniques', {
    params: { q: query },
  });
  return data;
}
