Files
Homarr/packages/api/src/open-api.ts

20 lines
524 B
TypeScript
Raw Normal View History

2024-11-23 22:05:44 +01:00
import { generateOpenApiDocument } from "trpc-to-openapi";
2024-08-25 18:03:32 +02:00
import { appRouter } from "./root";
export const openApiDocument = (base: string) =>
generateOpenApiDocument(appRouter, {
title: "Homarr API documentation",
version: "1.0.0",
baseUrl: base,
docsUrl: "https://homarr.dev",
securitySchemes: {
apikey: {
type: "apiKey",
name: "ApiKey",
description: "API key which can be obtained in the Homarr administration dashboard",
in: "header",
},
},
2024-08-25 18:03:32 +02:00
});