implement sse
This commit is contained in:
@@ -1,21 +1,14 @@
|
||||
import type { FastifyInstance, FastifyReply, FastifyRequest } from "fastify";
|
||||
import type { FastifyInstance } from "fastify";
|
||||
import { z } from "zod";
|
||||
import type { TidalService } from "../tidal/service.js";
|
||||
import { HomeAssistantService } from "../homeassistant/service.js";
|
||||
import { HomepageService } from "./service.js";
|
||||
import { API_HA_DeskPosition, TidalGetCurrent } from "@dpu/shared";
|
||||
import { type HomepageService } from "./service.js";
|
||||
import { type API_HA_DeskPosition, type TidalGetCurrent } from "@dpu/shared";
|
||||
|
||||
export async function homepageRoutes(
|
||||
fastify: FastifyInstance,
|
||||
{
|
||||
hpService,
|
||||
verifyAPIKey,
|
||||
}: {
|
||||
hpService: HomepageService
|
||||
verifyAPIKey: (
|
||||
request: FastifyRequest,
|
||||
reply: FastifyReply,
|
||||
) => Promise<void>;
|
||||
hpService: HomepageService;
|
||||
},
|
||||
) {
|
||||
fastify.get(
|
||||
|
||||
Reference in New Issue
Block a user