From cf97bace33fdd14f29ce947d55d17cba8fa85c11 Mon Sep 17 00:00:00 2001 From: Mohamed Bassem Date: Sun, 13 Apr 2025 01:27:45 +0000 Subject: feat: Add an MCP server for karakeep --- packages/open-api/lib/highlights.ts | 41 +++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) (limited to 'packages/open-api/lib/highlights.ts') diff --git a/packages/open-api/lib/highlights.ts b/packages/open-api/lib/highlights.ts index 2e4ec2d1..6eb1970e 100644 --- a/packages/open-api/lib/highlights.ts +++ b/packages/open-api/lib/highlights.ts @@ -11,6 +11,7 @@ import { } from "@karakeep/shared/types/highlights"; import { BearerAuth } from "./common"; +import { ErrorSchema } from "./errors"; import { PaginationSchema } from "./pagination"; export const registry = new OpenAPIRegistry(); @@ -84,6 +85,22 @@ registry.registerPath({ }, }, }, + 400: { + description: "Bad highlight request", + content: { + "application/json": { + schema: ErrorSchema, + }, + }, + }, + 404: { + description: "Bookmark not found", + content: { + "application/json": { + schema: ErrorSchema, + }, + }, + }, }, }); registry.registerPath({ @@ -105,6 +122,14 @@ registry.registerPath({ }, }, }, + 404: { + description: "Highlight not found", + content: { + "application/json": { + schema: ErrorSchema, + }, + }, + }, }, }); @@ -127,6 +152,14 @@ registry.registerPath({ }, }, }, + 404: { + description: "Highlight not found", + content: { + "application/json": { + schema: ErrorSchema, + }, + }, + }, }, }); @@ -158,5 +191,13 @@ registry.registerPath({ }, }, }, + 404: { + description: "Highlight not found", + content: { + "application/json": { + schema: ErrorSchema, + }, + }, + }, }, }); -- cgit v1.2.3-70-g09d2