aboutsummaryrefslogtreecommitdiffstats
path: root/packages/open-api/index.ts
diff options
context:
space:
mode:
Diffstat (limited to 'packages/open-api/index.ts')
-rw-r--r--packages/open-api/index.ts9
1 files changed, 2 insertions, 7 deletions
diff --git a/packages/open-api/index.ts b/packages/open-api/index.ts
index da5b3729..8682c208 100644
--- a/packages/open-api/index.ts
+++ b/packages/open-api/index.ts
@@ -3,7 +3,6 @@ import {
OpenApiGeneratorV3,
OpenAPIRegistry,
} from "@asteasolutions/zod-to-openapi";
-import * as yaml from "yaml";
import { registry as bookmarksRegistry } from "./lib/bookmarks";
import { registry as commonRegistry } from "./lib/common";
@@ -32,13 +31,9 @@ function getOpenApiDocumentation() {
}
function writeDocumentation() {
- // OpenAPI JSON
const docs = getOpenApiDocumentation();
-
- // YAML equivalent
- const fileContent = yaml.stringify(docs);
-
- fs.writeFileSync(`./openapi-spec.yml`, fileContent, {
+ const fileContent = JSON.stringify(docs, null, 2);
+ fs.writeFileSync(`./hoarder-openapi-spec.json`, fileContent, {
encoding: "utf-8",
});
}