/**
 * Direct MCP Server Module
 *
 * Provides programmatic access to FrontMCP servers without HTTP/stdio transports.
 *
 * @module direct
 */

// ─────────────────────────────────────────────────────────────────────────────
// Client Types
// ─────────────────────────────────────────────────────────────────────────────

export type {
  DirectClient,
  ConnectOptions,
  LLMConnectOptions,
  SessionOptions,
  ClientInfo,
  LLMPlatform,
  // Skills types
  SearchSkillsOptions,
  SearchSkillsResult,
  SkillSearchResultItem,
  LoadSkillsOptions,
  LoadSkillsResult,
  LoadedSkillItem,
  ListSkillsOptions,
  ListSkillsResult,
  // Elicitation types
  ElicitationRequest,
  ElicitationResponse,
  ElicitationHandler,
  // Completion types
  CompleteOptions,
  CompleteResult,
  // Logging types
  McpLogLevel,
  // Job types
  ListJobsOptions,
  ListJobsResult,
  ExecuteJobOptions,
  JobExecutionResult,
  JobStatusResult,
  // Workflow types
  ListWorkflowsOptions,
  ListWorkflowsResult,
  ExecuteWorkflowOptions,
  WorkflowExecutionResult,
  WorkflowStatusResult,
  // Build-time asset types
  SkillAssetEntry,
  SkillAssetManifest,
  // SEP-2640 (Skills Extension)
  Sep2640IndexEntry,
  Sep2640SkillEntry,
  Sep2640ResourceTemplateEntry,
  Sep2640ArchiveEntry,
} from './client.types';

// ─────────────────────────────────────────────────────────────────────────────
// Connect Utilities
// ─────────────────────────────────────────────────────────────────────────────

export { connect, connectOpenAI, connectClaude, connectLangChain, connectVercelAI } from './connect';

// ─────────────────────────────────────────────────────────────────────────────
// Implementation (for advanced use)
// ─────────────────────────────────────────────────────────────────────────────

export { DirectClientImpl } from './direct-client';
export { detectPlatform, formatToolsForPlatform, formatResultForPlatform, PLATFORM_CLIENT_INFO } from './llm-platform';
export type {
  OpenAITool,
  ClaudeTool,
  LangChainTool,
  VercelAITool,
  VercelAITools,
  FormattedToolResult,
  FormattedTools,
} from './llm-platform';

// ─────────────────────────────────────────────────────────────────────────────
// Legacy Direct Server (bypasses transport, invokes flows directly)
// ─────────────────────────────────────────────────────────────────────────────

export type { DirectMcpServer, DirectAuthContext, DirectCallOptions, DirectRequestMetadata } from './direct.types';

export { DirectMcpServerImpl } from './direct-server';

// ─────────────────────────────────────────────────────────────────────────────
// create() Factory — flat-config server creation
// ─────────────────────────────────────────────────────────────────────────────

export { create, clearCreateCache } from './create';
export type { CreateConfig } from './create.types';
