Bot & Automation

Market AI

/root/hermes-projects/Market AI

src/smoke.ts text
import { createTradingService } from "./app";

async function main(): Promise<void> {
  const tradingService = createTradingService();
  const result = await tradingService.createSignal({
    chatId: 1,
    userId: 1,
    symbolCode: "XAUUSD",
    mode: "intraday"
  });

  console.log(
    JSON.stringify(
      {
        symbol: result.signal.symbol.code,
        action: result.signal.action,
        confidence: result.signal.confidence,
        orderPreview: Boolean(result.orderIntent),
        riskNotes: result.riskNotes
      },
      null,
      2
    )
  );
}

main().catch((error) => {
  const message = error instanceof Error ? error.message : "Unknown smoke error";
  console.error(message);
  process.exitCode = 1;
});