import { html, json, page } from "./lib/http.mjs"; export const routes = [ { method: "GET", path: "/healthz", handler: ({ res }) => { res.writeHead(200, { "content-type": "text/plain; charset=utf-8" }); res.end("ok"); }, }, { method: "GET", path: "/", handler: ({ res }) => html(res, page("Обменный пункт «Достык»", '

Обменный пункт «Достык»

Алматы, пр. Достык, 5. Ежедневно 9:00–21:00.

Калькулятор обмена

')), }, { method: "GET", path: "/convert", handler: ({ res }) => html(res, page("Калькулятор обмена", "

Калькулятор обмена

Скоро здесь будет калькулятор.

")) }, // Пересчёт: GET /api/convert?amount=10000&to=USD → { amount, to, rate, result } (result — до сотых). { method: "GET", path: "/api/convert", handler: ({ res }) => json(res, 501, { error: "Пока не сделано" }) }, ];