@fractary/codex 0.12.6 → 0.12.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.cts CHANGED
@@ -673,7 +673,7 @@ declare const CodexConfigSchema: z.ZodObject<{
673
673
  token?: string | undefined;
674
674
  }> | undefined;
675
675
  }>;
676
- type CodexConfig = z.infer<typeof CodexConfigSchema>;
676
+ type CodexConfig$1 = z.infer<typeof CodexConfigSchema>;
677
677
  declare const UnifiedConfigSchema: z.ZodObject<{
678
678
  file: z.ZodOptional<z.ZodObject<{
679
679
  schema_version: z.ZodString;
@@ -1231,7 +1231,7 @@ declare const UnifiedConfigSchema: z.ZodObject<{
1231
1231
  }> | undefined;
1232
1232
  } | undefined;
1233
1233
  }>;
1234
- type UnifiedConfig$1 = z.infer<typeof UnifiedConfigSchema>;
1234
+ type UnifiedConfig$2 = z.infer<typeof UnifiedConfigSchema>;
1235
1235
 
1236
1236
  interface ParseMetadataOptions {
1237
1237
  strict?: boolean;
@@ -1273,14 +1273,14 @@ declare function getDefaultDirectories(orgSlug: string): {
1273
1273
  systems: string;
1274
1274
  };
1275
1275
  declare function getDefaultRules(): SyncRules;
1276
- declare function getDefaultConfig(orgSlug: string): CodexConfig;
1276
+ declare function getDefaultConfig(orgSlug: string): CodexConfig$1;
1277
1277
 
1278
1278
  interface LoadConfigOptions {
1279
1279
  organizationSlug?: string;
1280
1280
  repoName?: string;
1281
1281
  env?: Record<string, string | undefined>;
1282
1282
  }
1283
- declare function loadConfig(options?: LoadConfigOptions): CodexConfig;
1283
+ declare function loadConfig(options?: LoadConfigOptions): CodexConfig$1;
1284
1284
 
1285
1285
  declare const CONFIG_SCHEMA_VERSION: "2.0";
1286
1286
  interface SyncPresetConfig {
@@ -1317,6 +1317,167 @@ interface GenerateSyncConfigOptions {
1317
1317
  }
1318
1318
  declare function generateSyncConfigFromPreset(presetName: string, org: string, codexRepo: string, options?: GenerateSyncConfigOptions): SyncPresetConfig | undefined;
1319
1319
 
1320
+ interface NameValidationResult {
1321
+ valid: boolean;
1322
+ error?: string;
1323
+ }
1324
+ interface DirectoryStructureResult {
1325
+ created: string[];
1326
+ alreadyExisted: string[];
1327
+ }
1328
+ interface GitignoreResult {
1329
+ created: boolean;
1330
+ updated: boolean;
1331
+ alreadyIgnored: boolean;
1332
+ path: string;
1333
+ }
1334
+ interface RemoteConfig {
1335
+ token?: string;
1336
+ }
1337
+ interface FileSourceConfig {
1338
+ type: 's3' | 'r2' | 'gcs' | 'local';
1339
+ bucket?: string;
1340
+ prefix?: string;
1341
+ region?: string;
1342
+ local: {
1343
+ base_path: string;
1344
+ };
1345
+ push?: {
1346
+ compress?: boolean;
1347
+ keep_local?: boolean;
1348
+ };
1349
+ auth?: {
1350
+ profile?: string;
1351
+ };
1352
+ }
1353
+ interface FilePluginConfig {
1354
+ schema_version: string;
1355
+ sources: Record<string, FileSourceConfig>;
1356
+ }
1357
+ interface UnifiedConfig$1 {
1358
+ file?: FilePluginConfig;
1359
+ codex?: CodexConfig;
1360
+ [section: string]: unknown;
1361
+ }
1362
+ interface CodexConfig {
1363
+ schema_version: string;
1364
+ organization: string;
1365
+ project: string;
1366
+ codex_repo: string;
1367
+ sync?: SyncPresetConfig;
1368
+ remotes?: Record<string, RemoteConfig>;
1369
+ }
1370
+ interface DiscoverCodexRepoResult {
1371
+ repo: string | null;
1372
+ error?: 'gh_not_installed' | 'auth_failed' | 'org_not_found' | 'no_repos_found' | 'unknown';
1373
+ message?: string;
1374
+ }
1375
+ interface McpInstallResult {
1376
+ installed: boolean;
1377
+ migrated: boolean;
1378
+ alreadyInstalled: boolean;
1379
+ backupPath?: string;
1380
+ }
1381
+ interface CodexInitOptions {
1382
+ organization: string;
1383
+ project: string;
1384
+ codexRepo: string;
1385
+ syncPreset?: string;
1386
+ force?: boolean;
1387
+ skipMcp?: boolean;
1388
+ }
1389
+ interface CodexInitResult {
1390
+ configPath: string;
1391
+ codexSectionCreated: boolean;
1392
+ directories: DirectoryStructureResult;
1393
+ gitignore: GitignoreResult;
1394
+ mcp?: McpInstallResult;
1395
+ }
1396
+ interface CodexUpdateOptions {
1397
+ organization?: string;
1398
+ project?: string;
1399
+ codexRepo?: string;
1400
+ syncPreset?: string;
1401
+ skipMcp?: boolean;
1402
+ }
1403
+ interface CodexUpdateResult {
1404
+ configPath: string;
1405
+ fieldsUpdated: string[];
1406
+ mcp?: McpInstallResult;
1407
+ }
1408
+ interface ValidationIssue {
1409
+ field: string;
1410
+ message: string;
1411
+ severity: 'error' | 'warning';
1412
+ }
1413
+ interface CodexValidateResult {
1414
+ valid: boolean;
1415
+ configPath: string;
1416
+ errors: ValidationIssue[];
1417
+ warnings: ValidationIssue[];
1418
+ }
1419
+ interface ConfigInitOptions {
1420
+ organization: string;
1421
+ project: string;
1422
+ codexRepo: string;
1423
+ syncPreset?: string;
1424
+ force?: boolean;
1425
+ skipMcp?: boolean;
1426
+ includeFilePlugin?: boolean;
1427
+ }
1428
+ interface ConfigInitResult {
1429
+ configPath: string;
1430
+ configCreated: boolean;
1431
+ configMerged: boolean;
1432
+ directories: DirectoryStructureResult;
1433
+ gitignore: GitignoreResult;
1434
+ mcp?: McpInstallResult;
1435
+ }
1436
+ declare function validateNameFormat(name: string, type: 'organization' | 'repository'): NameValidationResult;
1437
+ declare function validateOrganizationName(name: string): void;
1438
+ declare function validateRepositoryName(name: string): void;
1439
+ declare function detectOrganizationFromGit(projectRoot: string): Promise<string | null>;
1440
+ declare function detectProjectName(projectRoot: string): string;
1441
+ declare const STANDARD_DIRECTORIES: readonly [".fractary", ".fractary/specs", ".fractary/logs", ".fractary/codex", ".fractary/codex/cache"];
1442
+ declare const CODEX_DIRECTORIES: readonly [".fractary/codex", ".fractary/codex/cache"];
1443
+ declare function ensureDirectoryStructure(projectRoot: string, directories?: readonly string[]): Promise<DirectoryStructureResult>;
1444
+ declare const DEFAULT_FRACTARY_GITIGNORE = "# .fractary/.gitignore\n# This file is managed by multiple plugins - each plugin manages its own section\n\n# ===== fractary-codex (managed) =====\ncodex/cache/\n# ===== end fractary-codex =====\n";
1445
+ declare function normalizeCachePath(cachePath: string): string;
1446
+ declare function ensureCachePathIgnored(projectRoot: string, cachePath?: string): Promise<GitignoreResult>;
1447
+ declare function installMcpServer(projectRoot: string, configPath?: string, options?: {
1448
+ backup?: boolean;
1449
+ }): Promise<McpInstallResult>;
1450
+ declare function discoverCodexRepo(org: string): Promise<DiscoverCodexRepoResult>;
1451
+ declare function sanitizeForS3BucketName(name: string): string;
1452
+ declare function generateCodexSection(organization: string, project: string, codexRepo: string, options?: {
1453
+ syncPreset?: string;
1454
+ }): CodexConfig;
1455
+ declare function generateUnifiedConfig(organization: string, project: string, codexRepo: string, options?: {
1456
+ syncPreset?: string;
1457
+ includeFilePlugin?: boolean;
1458
+ }): UnifiedConfig$1;
1459
+ declare function readUnifiedConfig$1(configPath: string): Promise<UnifiedConfig$1 | null>;
1460
+ declare function writeUnifiedConfig(config: UnifiedConfig$1, outputPath: string): Promise<void>;
1461
+ declare function mergeUnifiedConfigs(existing: UnifiedConfig$1, updates: UnifiedConfig$1): UnifiedConfig$1;
1462
+ declare class ConfigManager {
1463
+ private projectRoot;
1464
+ constructor(projectRoot: string);
1465
+ getProjectRoot(): string;
1466
+ getConfigPath(): string;
1467
+ detectOrganization(): Promise<string | null>;
1468
+ detectProject(): string;
1469
+ discoverCodexRepo(org: string): Promise<DiscoverCodexRepoResult>;
1470
+ readConfig(): Promise<UnifiedConfig$1 | null>;
1471
+ writeConfig(config: UnifiedConfig$1): Promise<void>;
1472
+ configExists(): Promise<boolean>;
1473
+ codexSectionExists(): Promise<boolean>;
1474
+ initializeCodexSection(options: CodexInitOptions): Promise<CodexInitResult>;
1475
+ updateCodexSection(options: CodexUpdateOptions): Promise<CodexUpdateResult>;
1476
+ validateCodexConfig(): Promise<CodexValidateResult>;
1477
+ initialize(options: ConfigInitOptions): Promise<ConfigInitResult>;
1478
+ }
1479
+ declare function createConfigManager(projectRoot?: string): ConfigManager;
1480
+
1320
1481
  interface ShouldSyncOptions {
1321
1482
  filePath: string;
1322
1483
  fileMetadata: Metadata;
@@ -1408,7 +1569,7 @@ declare class HttpStorage implements StorageProvider {
1408
1569
  declare function createHttpStorage(options?: HttpStorageOptions): HttpStorage;
1409
1570
 
1410
1571
  interface FilePluginStorageOptions {
1411
- config: UnifiedConfig$1;
1572
+ config: UnifiedConfig$2;
1412
1573
  enableS3Fallback?: boolean;
1413
1574
  baseDir?: string;
1414
1575
  }
@@ -1456,7 +1617,7 @@ interface StorageManagerConfig {
1456
1617
  filePlugin?: FilePluginStorageOptions;
1457
1618
  priority?: StorageProviderType$1[];
1458
1619
  enableCaching?: boolean;
1459
- codexConfig?: CodexConfig;
1620
+ codexConfig?: CodexConfig$1;
1460
1621
  }
1461
1622
  declare class StorageManager {
1462
1623
  private providers;
@@ -1569,6 +1730,28 @@ interface CacheLookupResult {
1569
1730
  fresh: boolean;
1570
1731
  source: 'memory' | 'disk' | 'network' | 'none';
1571
1732
  }
1733
+ interface CacheEntryInfo {
1734
+ uri: string;
1735
+ contentType: string;
1736
+ size: number;
1737
+ status: 'fresh' | 'stale' | 'expired';
1738
+ createdAt: number;
1739
+ expiresAt: number;
1740
+ remainingTtl: number;
1741
+ inMemory: boolean;
1742
+ }
1743
+ interface ListEntriesOptions {
1744
+ status?: 'fresh' | 'stale' | 'expired' | 'all';
1745
+ limit?: number;
1746
+ offset?: number;
1747
+ sortBy?: 'uri' | 'size' | 'createdAt' | 'expiresAt';
1748
+ sortDirection?: 'asc' | 'desc';
1749
+ }
1750
+ interface ListEntriesResult {
1751
+ entries: CacheEntryInfo[];
1752
+ total: number;
1753
+ hasMore: boolean;
1754
+ }
1572
1755
  declare class CacheManager {
1573
1756
  private memoryCache;
1574
1757
  private persistence;
@@ -1595,6 +1778,8 @@ declare class CacheManager {
1595
1778
  preload(references: ResolvedReference[], options?: FetchOptions): Promise<void>;
1596
1779
  getMetadata(uri: string): Promise<CacheEntryMetadata | null>;
1597
1780
  getTtl(uri: string): Promise<number | null>;
1781
+ listEntries(options?: ListEntriesOptions): Promise<ListEntriesResult>;
1782
+ listUris(): Promise<string[]>;
1598
1783
  private fetchAndCache;
1599
1784
  private backgroundRefresh;
1600
1785
  private setMemoryEntry;
@@ -2157,4 +2342,106 @@ declare function formatSeconds(seconds: number): string;
2157
2342
  declare function isValidDuration(value: string): boolean;
2158
2343
  declare function isValidSize(value: string): boolean;
2159
2344
 
2160
- export { type ArchiveConfig, type ArtifactType, type AutoSyncPattern, AutoSyncPatternSchema, BUILT_IN_TYPES, CODEX_URI_PREFIX, CONFIG_SCHEMA_VERSION, type CacheEntry, type CacheEntryMetadata, type CacheEntryStatus, type CacheLookupResult, CacheManager, type CacheManagerConfig, CachePersistence, type CachePersistenceOptions, type CacheStats, type CodexConfig, CodexConfigSchema, CodexError, type CodexYamlConfig, CommonRules, ConfigurationError, type ConversionOptions, type ConvertedReference, type CustomSyncDestination, type CustomTypeConfig$1 as CustomTypeConfig, CustomTypeSchema, DEFAULT_CACHE_DIR, DEFAULT_FETCH_OPTIONS, DEFAULT_GLOBAL_EXCLUDES, DEFAULT_MIGRATION_OPTIONS, DEFAULT_PERMISSION_CONFIG, DEFAULT_SYNC_CONFIG, DEFAULT_TYPE, type DirectionalSyncConfig, type EvaluationResult, type EvaluationSummary, type ExpandEnvOptions, type FetchOptions, type FetchResult, type FileConfig, type FileInfo, FilePluginFileNotFoundError, type FilePluginFileNotFoundErrorOptions, FilePluginStorage, type FilePluginStorageOptions, type FileSyncStatus, type GenerateSyncConfigOptions, GitHubStorage, type GitHubStorageOptions, HttpStorage, type HttpStorageOptions, LEGACY_PATTERNS, LEGACY_REF_PREFIX, type LegacyAutoSyncPattern, type LegacyCodexConfig, type LoadConfigOptions, LocalStorage, type LocalStorageOptions, type Metadata, MetadataSchema, type MigrationChange, type MigrationOptions, type MigrationResult, type ModernCodexConfig, type ModernSyncPattern, PERMISSION_LEVEL_ORDER, type ParseMetadataOptions, type ParseOptions, type ParseResult, type ParsedReference, type PermissionAction, type PermissionConfig, type PermissionContext, PermissionDeniedError, type PermissionLevel$1 as PermissionLevel, PermissionManager, type PermissionManagerConfig, type PermissionResult, type PermissionRule$1 as PermissionRule, type PermissionScope, type PlanStats, type ReadConfigOptions, type ReferenceConversionResult, type ResolveOptions, type ResolveOrgOptions, type ResolvedReference, SYNC_PATTERN_PRESETS, type SerializedCacheEntry, type ShouldSyncOptions, StorageManager, type StorageManagerConfig, type StorageProvider, type StorageProviderConfig$1 as StorageProviderConfig, type StorageProviderType$1 as StorageProviderType, type SyncConfig$1 as SyncConfig, type SyncDirection, SyncManager, type SyncManagerConfig, type SyncManifest, type SyncManifestEntry, type SyncOperation, type SyncOptions, type SyncPlan, type SyncPreset, type SyncPresetConfig, type SyncResult, type SyncRule$1 as SyncRule, type SyncRules, SyncRulesSchema, TTL, TypeRegistry, type TypeRegistryOptions, type TypesConfig$1 as TypesConfig, TypesConfigSchema, type UnifiedConfig, ValidationError, type VersionDetectionResult, type CacheConfig as YamlCacheConfig, type CustomTypeConfig as YamlCustomTypeConfig, type GitHubStorageConfig as YamlGitHubStorageConfig, type HttpStorageConfig as YamlHttpStorageConfig, type LocalStorageConfig as YamlLocalStorageConfig, type McpConfig as YamlMcpConfig, type PermissionLevel as YamlPermissionLevel, type PermissionRule as YamlPermissionRule, type PermissionsConfig as YamlPermissionsConfig, type S3StorageConfig as YamlS3StorageConfig, type StorageProviderConfig as YamlStorageProviderConfig, type StorageProviderType as YamlStorageProviderType, type SyncConfig as YamlSyncConfig, type SyncRule as YamlSyncRule, type TypesConfig as YamlTypesConfig, buildUri, calculateCachePath, calculateContentHash, convertLegacyReference, convertLegacyReferences, convertToUri, createCacheEntry, createCacheManager, createCachePersistence, createDefaultRegistry, createEmptyModernConfig, createEmptySyncPlan, createGitHubStorage, createHttpStorage, createLocalStorage, createPermissionManager, createRule, createRulesFromPatterns, createStorageManager, createSyncManager, createSyncPlan, deserializeCacheEntry, detectContentType, detectCurrentProject, detectVersion, estimateSyncTime, evaluatePath, evaluatePaths, evaluatePatterns, evaluatePermission, evaluatePermissions, expandEnvVars, expandEnvVarsInConfig, extendType, extractEnvVarNames, extractOrgFromRepoName, extractRawFrontmatter, filterByPatterns, filterByPermission, filterPlanOperations, filterSyncablePaths, findLegacyReferences, formatBytes, formatDuration, formatPlanSummary, formatSeconds, generateMigrationReport, generateReferenceMigrationSummary, generateSyncConfigFromPreset, getBuiltInType, getBuiltInTypeNames, getCacheEntryAge, getCacheEntryStatus, getCurrentContext, getCustomSyncDestinations, getDefaultCacheManager, getDefaultConfig, getDefaultDirectories, getDefaultPermissionManager, getDefaultRules, getDefaultStorageManager, getDirectory, getExtension, getFilename, getMigrationRequirements, getPlanStats, getRelativeCachePath, getRemainingTtl, getSyncPreset, getSyncPresetNames, getTargetRepos, hasContentChanged, hasEnvVars, hasFrontmatter, hasLegacyReferences, hasPermission as hasPermissionLevel, isBuiltInType, isCacheEntryFresh, isCacheEntryValid, isCurrentProjectUri, isLegacyConfig, isLegacyReference, isModernConfig, isAllowed as isPermissionAllowed, isUnifiedConfig, isValidDuration, isValidSize, isValidUri, levelGrants, loadConfig, loadCustomTypes, matchAnyPattern, matchPattern, maxLevel, mergeFetchOptions, mergeRules, mergeTypes, migrateConfig, migrateFileReferences, minLevel, needsMigration, parseCustomDestination, parseDuration, parseMetadata, parseReference, parseSize, parseTtl, readCodexConfig, readUnifiedConfig, resolveOrganization, resolveReference, resolveReferences, ruleMatchesAction, ruleMatchesContext, ruleMatchesPath, sanitizePath, serializeCacheEntry, setDefaultCacheManager, setDefaultPermissionManager, setDefaultStorageManager, shouldSyncToRepo, substitutePatternPlaceholders, summarizeEvaluations, touchCacheEntry, validateCustomTypes, validateMetadata, validateMigratedConfig, validateOrg, validatePath, validateRules as validatePermissionRules, validateProject, validateRules$1 as validateRules, validateUri };
2345
+ type HealthStatus = 'pass' | 'warn' | 'fail';
2346
+ interface HealthCheck {
2347
+ name: string;
2348
+ status: HealthStatus;
2349
+ message: string;
2350
+ details?: string;
2351
+ }
2352
+ interface HealthSummary {
2353
+ total: number;
2354
+ passed: number;
2355
+ warned: number;
2356
+ failed: number;
2357
+ healthy: boolean;
2358
+ status: 'healthy' | 'degraded' | 'unhealthy';
2359
+ }
2360
+ interface HealthResult {
2361
+ summary: HealthSummary;
2362
+ checks: HealthCheck[];
2363
+ }
2364
+ interface StorageProviderInfo {
2365
+ type: string;
2366
+ [key: string]: unknown;
2367
+ }
2368
+ interface HealthConfig {
2369
+ organization?: string;
2370
+ storage?: StorageProviderInfo[];
2371
+ codex?: {
2372
+ organization?: string;
2373
+ codex_repo?: string;
2374
+ };
2375
+ }
2376
+ interface HealthCheckerOptions {
2377
+ projectRoot?: string;
2378
+ cacheManager?: CacheManager;
2379
+ typeRegistry?: TypeRegistry;
2380
+ config?: HealthConfig;
2381
+ }
2382
+ declare class HealthChecker {
2383
+ private projectRoot;
2384
+ private cacheManager?;
2385
+ private typeRegistry?;
2386
+ private config?;
2387
+ constructor(options?: HealthCheckerOptions);
2388
+ getConfigPath(): string;
2389
+ getLegacyConfigPath(): string;
2390
+ checkConfiguration(): Promise<HealthCheck>;
2391
+ checkCache(): Promise<HealthCheck>;
2392
+ checkCacheFromStats(stats: CacheStats): HealthCheck;
2393
+ checkStorage(): Promise<HealthCheck>;
2394
+ checkTypes(): HealthCheck;
2395
+ checkTypesFromRegistry(registry: TypeRegistry): HealthCheck;
2396
+ runAll(): Promise<HealthResult>;
2397
+ run(checkNames: string[]): Promise<HealthResult>;
2398
+ summarize(checks: HealthCheck[]): HealthResult;
2399
+ }
2400
+ declare function createHealthChecker(options?: HealthCheckerOptions): HealthChecker;
2401
+
2402
+ interface CodexClientOptions {
2403
+ configPath?: string;
2404
+ cacheDir?: string;
2405
+ organizationSlug?: string;
2406
+ }
2407
+ interface ClientFetchOptions {
2408
+ bypassCache?: boolean;
2409
+ ttl?: number;
2410
+ branch?: string;
2411
+ }
2412
+ interface ClientFetchResult {
2413
+ content: Buffer;
2414
+ fromCache: boolean;
2415
+ contentType?: string;
2416
+ metadata?: {
2417
+ fetchedAt?: string;
2418
+ expiresAt?: string;
2419
+ contentLength?: number;
2420
+ };
2421
+ }
2422
+ declare class CodexClient {
2423
+ private cache;
2424
+ private storage;
2425
+ private types;
2426
+ private organization;
2427
+ private unifiedConfig;
2428
+ private constructor();
2429
+ static create(options?: CodexClientOptions): Promise<CodexClient>;
2430
+ fetch(uri: string, options?: ClientFetchOptions): Promise<ClientFetchResult>;
2431
+ invalidateCache(pattern?: string): Promise<void>;
2432
+ invalidateCachePattern(regex: RegExp): Promise<number>;
2433
+ getCacheStats(): Promise<CacheStats & {
2434
+ memoryEntries: number;
2435
+ memorySize: number;
2436
+ }>;
2437
+ listCacheEntries(options?: ListEntriesOptions): Promise<ListEntriesResult>;
2438
+ getHealthChecks(): Promise<HealthCheck[]>;
2439
+ getTypeRegistry(): TypeRegistry;
2440
+ getCacheManager(): CacheManager;
2441
+ getStorageManager(): StorageManager;
2442
+ getOrganization(): string;
2443
+ getUnifiedConfig(): UnifiedConfig | null;
2444
+ }
2445
+ declare function createCodexClient(options?: CodexClientOptions): Promise<CodexClient>;
2446
+
2447
+ export { type ArchiveConfig, type ArtifactType, type AutoSyncPattern, AutoSyncPatternSchema, BUILT_IN_TYPES, CODEX_DIRECTORIES, CODEX_URI_PREFIX, CONFIG_SCHEMA_VERSION, type CacheEntry, type CacheEntryInfo, type CacheEntryMetadata, type CacheEntryStatus, type CacheLookupResult, CacheManager, type CacheManagerConfig, CachePersistence, type CachePersistenceOptions, type CacheStats, type ClientFetchOptions, type ClientFetchResult, CodexClient, type CodexClientOptions, type CodexConfig, CodexConfigSchema, CodexError, type CodexInitOptions, type CodexInitResult, type CodexUpdateOptions, type CodexUpdateResult, type CodexValidateResult, type CodexYamlConfig, CommonRules, type ConfigInitOptions, type ConfigInitResult, ConfigManager, ConfigurationError, type ConversionOptions, type ConvertedReference, type CustomSyncDestination, type CustomTypeConfig$1 as CustomTypeConfig, CustomTypeSchema, DEFAULT_CACHE_DIR, DEFAULT_FETCH_OPTIONS, DEFAULT_FRACTARY_GITIGNORE, DEFAULT_GLOBAL_EXCLUDES, DEFAULT_MIGRATION_OPTIONS, DEFAULT_PERMISSION_CONFIG, DEFAULT_SYNC_CONFIG, DEFAULT_TYPE, type DirectionalSyncConfig, type DirectoryStructureResult, type DiscoverCodexRepoResult, type EvaluationResult, type EvaluationSummary, type ExpandEnvOptions, type FetchOptions, type FetchResult, type FileConfig, type FileInfo, type FilePluginConfig, FilePluginFileNotFoundError, type FilePluginFileNotFoundErrorOptions, FilePluginStorage, type FilePluginStorageOptions, type FileSourceConfig, type FileSyncStatus, type GenerateSyncConfigOptions, GitHubStorage, type GitHubStorageOptions, type GitignoreResult, type HealthCheck, HealthChecker, type HealthCheckerOptions, type HealthConfig, type HealthResult, type HealthStatus, type HealthSummary, HttpStorage, type HttpStorageOptions, LEGACY_PATTERNS, LEGACY_REF_PREFIX, type LegacyAutoSyncPattern, type LegacyCodexConfig, type ListEntriesOptions, type ListEntriesResult, type LoadConfigOptions, LocalStorage, type LocalStorageOptions, type McpInstallResult, type Metadata, MetadataSchema, type MigrationChange, type MigrationOptions, type MigrationResult, type ModernCodexConfig, type ModernSyncPattern, type NameValidationResult, PERMISSION_LEVEL_ORDER, type ParseMetadataOptions, type ParseOptions, type ParseResult, type ParsedReference, type PermissionAction, type PermissionConfig, type PermissionContext, PermissionDeniedError, type PermissionLevel$1 as PermissionLevel, PermissionManager, type PermissionManagerConfig, type PermissionResult, type PermissionRule$1 as PermissionRule, type PermissionScope, type PlanStats, type ReadConfigOptions, type ReferenceConversionResult, type RemoteConfig, type ResolveOptions, type ResolveOrgOptions, type ResolvedReference, STANDARD_DIRECTORIES, SYNC_PATTERN_PRESETS, type CodexConfig$1 as SchemaCodexConfig, type SerializedCacheEntry, type ShouldSyncOptions, StorageManager, type StorageManagerConfig, type StorageProvider, type StorageProviderConfig$1 as StorageProviderConfig, type StorageProviderInfo, type StorageProviderType$1 as StorageProviderType, type SyncConfig$1 as SyncConfig, type SyncDirection, SyncManager, type SyncManagerConfig, type SyncManifest, type SyncManifestEntry, type SyncOperation, type SyncOptions, type SyncPlan, type SyncPreset, type SyncPresetConfig, type SyncResult, type SyncRule$1 as SyncRule, type SyncRules, SyncRulesSchema, TTL, TypeRegistry, type TypeRegistryOptions, type TypesConfig$1 as TypesConfig, TypesConfigSchema, type UnifiedConfig$1 as UnifiedConfig, ValidationError, type ValidationIssue, type VersionDetectionResult, type CacheConfig as YamlCacheConfig, type CustomTypeConfig as YamlCustomTypeConfig, type GitHubStorageConfig as YamlGitHubStorageConfig, type HttpStorageConfig as YamlHttpStorageConfig, type LocalStorageConfig as YamlLocalStorageConfig, type McpConfig as YamlMcpConfig, type PermissionLevel as YamlPermissionLevel, type PermissionRule as YamlPermissionRule, type PermissionsConfig as YamlPermissionsConfig, type S3StorageConfig as YamlS3StorageConfig, type StorageProviderConfig as YamlStorageProviderConfig, type StorageProviderType as YamlStorageProviderType, type SyncConfig as YamlSyncConfig, type SyncRule as YamlSyncRule, type TypesConfig as YamlTypesConfig, type UnifiedConfig as YamlUnifiedConfig, buildUri, calculateCachePath, calculateContentHash, convertLegacyReference, convertLegacyReferences, convertToUri, createCacheEntry, createCacheManager, createCachePersistence, createCodexClient, createConfigManager, createDefaultRegistry, createEmptyModernConfig, createEmptySyncPlan, createGitHubStorage, createHealthChecker, createHttpStorage, createLocalStorage, createPermissionManager, createRule, createRulesFromPatterns, createStorageManager, createSyncManager, createSyncPlan, deserializeCacheEntry, detectContentType, detectCurrentProject, detectOrganizationFromGit, detectProjectName, detectVersion, discoverCodexRepo, ensureCachePathIgnored, ensureDirectoryStructure, estimateSyncTime, evaluatePath, evaluatePaths, evaluatePatterns, evaluatePermission, evaluatePermissions, expandEnvVars, expandEnvVarsInConfig, extendType, extractEnvVarNames, extractOrgFromRepoName, extractRawFrontmatter, filterByPatterns, filterByPermission, filterPlanOperations, filterSyncablePaths, findLegacyReferences, formatBytes, formatDuration, formatPlanSummary, formatSeconds, generateCodexSection, generateMigrationReport, generateReferenceMigrationSummary, generateSyncConfigFromPreset, generateUnifiedConfig, getBuiltInType, getBuiltInTypeNames, getCacheEntryAge, getCacheEntryStatus, getCurrentContext, getCustomSyncDestinations, getDefaultCacheManager, getDefaultConfig, getDefaultDirectories, getDefaultPermissionManager, getDefaultRules, getDefaultStorageManager, getDirectory, getExtension, getFilename, getMigrationRequirements, getPlanStats, getRelativeCachePath, getRemainingTtl, getSyncPreset, getSyncPresetNames, getTargetRepos, hasContentChanged, hasEnvVars, hasFrontmatter, hasLegacyReferences, hasPermission as hasPermissionLevel, installMcpServer, isBuiltInType, isCacheEntryFresh, isCacheEntryValid, isCurrentProjectUri, isLegacyConfig, isLegacyReference, isModernConfig, isAllowed as isPermissionAllowed, isUnifiedConfig, isValidDuration, isValidSize, isValidUri, levelGrants, loadConfig, loadCustomTypes, matchAnyPattern, matchPattern, maxLevel, mergeFetchOptions, mergeRules, mergeTypes, mergeUnifiedConfigs, migrateConfig, migrateFileReferences, minLevel, needsMigration, normalizeCachePath, parseCustomDestination, parseDuration, parseMetadata, parseReference, parseSize, parseTtl, readCodexConfig, readUnifiedConfig$1 as readUnifiedConfig, readUnifiedConfig as readYamlUnifiedConfig, resolveOrganization, resolveReference, resolveReferences, ruleMatchesAction, ruleMatchesContext, ruleMatchesPath, sanitizeForS3BucketName, sanitizePath, serializeCacheEntry, setDefaultCacheManager, setDefaultPermissionManager, setDefaultStorageManager, shouldSyncToRepo, substitutePatternPlaceholders, summarizeEvaluations, touchCacheEntry, validateCustomTypes, validateMetadata, validateMigratedConfig, validateNameFormat, validateOrg, validateOrganizationName, validatePath, validateRules as validatePermissionRules, validateProject, validateRepositoryName, validateRules$1 as validateRules, validateUri, writeUnifiedConfig };