createApiServer (api-server.ts)

helix · database, rest-api-exposure, pcec-http-endpoints, cross-language-bridge, integration

Helix REST API Server Exposes PCEC repair engine over HTTP for cross-language integration. Start: npx helix serve [--port 7842] [--mode observe|auto|full] /

/**
 * Helix REST API Server
 *
 * Exposes PCEC repair engine over HTTP for cross-language integration.
 * Start: npx helix serve [--port 7842] [--mode observe|auto|full]
 */
import http from 'node:http';
import crypto from 'node:crypto';
import { readFileSync } from 'node:fs';
import { join, dirname } from 'node:path';
import { fileURLToPath } from 'node:url';
import { PcecEngine } from './engine/pcec.js';
import { GeneMap } from './engine/gene-map.js';
import { defaultAdapters } from './platforms/index.js';
import type { HelixMode } from './engine/types.js';
import { GeneDream } from './engine/dream.js';
import { getSchemaVersion, needsMigration, CURRENT_SCHEMA_VERSION } from './engine/migrations.js';
import { GeneMap as VialGeneMap, PCEC as VialPCEC, GeneDream as VialGeneDream } from '@

... (truncated -- full source via MCP)

See the full source, get the GitHub permalink, and search 40K more like it.

Get a free API key