@hiai-gg/docsmint 0.8.6 → 0.8.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +38 -26
- package/dist/backend/index.js +167 -140
- package/dist/mcp-cli.js +113 -68
- package/dist/mcp-server.d.ts +4 -0
- package/dist/mcp-server.js +113 -68
- package/package.json +2 -2
- package/packages/cli/src/index.ts +1 -1
- package/server.json +6 -6
package/dist/mcp-server.js
CHANGED
|
@@ -16,7 +16,7 @@ var __export = (target, all) => {
|
|
|
16
16
|
|
|
17
17
|
// ../mcp-server/src/server.ts
|
|
18
18
|
import { McpServer } from "@modelcontextprotocol/server";
|
|
19
|
-
import { z as
|
|
19
|
+
import { z as z13 } from "zod";
|
|
20
20
|
|
|
21
21
|
// dist/client.js
|
|
22
22
|
var docsApiErrorBrand = Symbol.for("io.github.hiai-gg.docsmint.DocsApiError");
|
|
@@ -577,52 +577,87 @@ var RESOURCE_PERMISSIONS = new Set([
|
|
|
577
577
|
"edit",
|
|
578
578
|
"write"
|
|
579
579
|
]);
|
|
580
|
-
// ../mcp-server/src/
|
|
580
|
+
// ../mcp-server/src/lifecycle.ts
|
|
581
581
|
import { z } from "zod";
|
|
582
|
+
function unsupported(name) {
|
|
583
|
+
throw new Error(`The injected legacy MCP client does not support ${name}; use a public DocsClient.`);
|
|
584
|
+
}
|
|
585
|
+
var annotations = { readOnlyHint: false, destructiveHint: true, idempotentHint: false, openWorldHint: false };
|
|
586
|
+
function registerLifecycleCapabilities(server, client, wrap) {
|
|
587
|
+
const deletions = [
|
|
588
|
+
{ name: "delete_document", description: "Move a document to trash. Requires write access to the document; category keys are limited to their category. Does not permanently purge content. Returns the document ID and deleted=true. Use only when the user intends deletion.", action: (id) => client.deleteDocument ? client.deleteDocument(id) : unsupported("delete_document"), idDescription: "UUID of the document to move to trash; obtain it from search_documents, list_documents, or get_document." },
|
|
589
|
+
{ name: "delete_folder", description: "Delete a folder while preserving its documents. Direct child folders and documents are detached according to the server folder rules, and reindexing is queued for affected documents. Requires write access in the permitted workspace or category. Returns the folder ID and deleted=true.", action: (id) => client.deleteFolder ? client.deleteFolder(id) : unsupported("delete_folder"), idDescription: "UUID of the folder to delete; obtain it from list_folders. This does not delete the documents inside it." },
|
|
590
|
+
{ name: "delete_category", description: "Delete a category and detach its folders and documents without deleting their content. Requires full workspace write access; category-scoped keys cannot delete any category, including their own. Returns the category ID and deleted=true.", action: (id) => client.deleteCategory ? client.deleteCategory(id) : unsupported("delete_category"), idDescription: "UUID of the category to delete; obtain it from list_categories using a workspace key." }
|
|
591
|
+
];
|
|
592
|
+
for (const tool of deletions) {
|
|
593
|
+
server.registerTool(tool.name, { description: tool.description, annotations, inputSchema: z.object({ id: z.string().uuid().describe(tool.idDescription) }) }, wrap(async ({ id }) => {
|
|
594
|
+
await tool.action(id);
|
|
595
|
+
return { id, deleted: true };
|
|
596
|
+
}));
|
|
597
|
+
}
|
|
598
|
+
server.registerTool("restore_document_version", {
|
|
599
|
+
description: "Restore document content from a version or named snapshot returned by get_version_history. Requires edit access to that document. The server backs up the current content, records the restoration, and queues document reindexing. Returns the updated document. Does not restore a document from trash or restore folder/category placement.",
|
|
600
|
+
annotations,
|
|
601
|
+
inputSchema: z.object({
|
|
602
|
+
documentId: z.string().uuid().describe("UUID of the document whose content should be restored; it must be visible in the active workspace or category."),
|
|
603
|
+
versionId: z.string().uuid().describe("UUID of a version belonging to this document, from get_version_history. Use the version ID, not a snapshot label.")
|
|
604
|
+
})
|
|
605
|
+
}, wrap(async ({ documentId, versionId }) => client.restoreDocumentVersion ? client.restoreDocumentVersion(documentId, versionId) : unsupported("restore_document_version")));
|
|
606
|
+
}
|
|
607
|
+
|
|
608
|
+
// ../mcp-server/src/capabilities.ts
|
|
609
|
+
import { z as z2 } from "zod";
|
|
582
610
|
function registerExtendedCapabilities(server, client, wrapHandler) {
|
|
583
611
|
server.registerTool("list_categories", {
|
|
612
|
+
annotations: { readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false },
|
|
584
613
|
description: "List categories visible to the API key. Category keys receive only their bound category.",
|
|
585
|
-
inputSchema:
|
|
614
|
+
inputSchema: z2.object({})
|
|
586
615
|
}, wrapHandler(async () => client.listCategories()));
|
|
587
616
|
server.registerTool("create_category", {
|
|
617
|
+
annotations: { readOnlyHint: false, destructiveHint: false, idempotentHint: false, openWorldHint: false },
|
|
588
618
|
description: "Create a category. Requires a workspace key with write access; category keys cannot mutate categories.",
|
|
589
|
-
inputSchema:
|
|
590
|
-
name:
|
|
591
|
-
description:
|
|
619
|
+
inputSchema: z2.object({
|
|
620
|
+
name: z2.string().min(1).describe("Non-empty display name for the new category, for example Project notes."),
|
|
621
|
+
description: z2.string().optional().describe("Optional plain-text explanation of the category purpose; omit if not needed.")
|
|
592
622
|
})
|
|
593
623
|
}, wrapHandler(async (input) => client.createCategory(input)));
|
|
594
624
|
server.registerTool("list_tags", {
|
|
625
|
+
annotations: { readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false },
|
|
595
626
|
description: "List tags visible in the workspace or bound category.",
|
|
596
|
-
inputSchema:
|
|
627
|
+
inputSchema: z2.object({})
|
|
597
628
|
}, wrapHandler(async () => client.listTags()));
|
|
598
629
|
server.registerTool("get_related_documents", {
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
630
|
+
annotations: { readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false },
|
|
631
|
+
description: "Find graph-related documents from one readable document, without a text query. Returns related documents and relation metadata. Use search_knowledge_graph to filter graph neighbors by text, or search_documents for normal retrieval. Results stay within the active scope and may be empty when graph data is unavailable.",
|
|
632
|
+
inputSchema: z2.object({
|
|
633
|
+
documentId: z2.string().min(1).describe("Document UUID returned by search_documents or list_documents; must be readable in the active scope."),
|
|
634
|
+
limit: z2.number().int().min(1).max(50).optional().describe("Maximum related documents to return, from 1 to 50. Omit to use the server default.")
|
|
603
635
|
})
|
|
604
636
|
}, wrapHandler(async ({ documentId, limit }) => client.getRelatedDocuments(documentId, limit)));
|
|
605
637
|
server.registerTool("search_knowledge_graph", {
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
638
|
+
annotations: { readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false },
|
|
639
|
+
description: "Retrieve graph context from one or more readable seed documents and filter/rank related documents by query text. Returns seed entities and relatedDocs; use search_documents first to obtain seed IDs. Returned documents stay within the active category. Graph data may be empty when unavailable.",
|
|
640
|
+
inputSchema: z2.object({
|
|
641
|
+
query: z2.string().min(1).max(1000).describe("Search text used to filter and rank graph-related documents. Preserve the original query language."),
|
|
642
|
+
docIds: z2.array(z2.string().min(1)).min(1).max(50).describe("Between 1 and 50 authorized document UUIDs from search_documents or list_documents to use as graph traversal seeds."),
|
|
643
|
+
limit: z2.number().int().min(1).max(50).optional().describe("Maximum related documents to return, from 1 to 50. Omit to use the server default.")
|
|
611
644
|
})
|
|
612
645
|
}, wrapHandler(async (input) => client.searchGraph(input)));
|
|
613
646
|
server.registerTool("get_document_index_status", {
|
|
614
|
-
|
|
615
|
-
|
|
647
|
+
annotations: { readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false },
|
|
648
|
+
description: "Read a document indexing and knowledge-pipeline status without starting any work. Use after a save or refresh_document_index to inspect progress and failures. Requires read access to the document.",
|
|
649
|
+
inputSchema: z2.object({ documentId: z2.string().min(1).describe("Document UUID returned by search_documents or list_documents; must be readable in the active scope.") })
|
|
616
650
|
}, wrapHandler(async ({ documentId }) => client.getDocumentIndexStatus(documentId)));
|
|
617
651
|
server.registerTool("refresh_document_index", {
|
|
618
|
-
|
|
619
|
-
|
|
652
|
+
annotations: { readOnlyHint: false, destructiveHint: false, idempotentHint: false, openWorldHint: false },
|
|
653
|
+
description: "Queue document reindexing and return the server acknowledgment; processing completes asynchronously. Requires write access. Normal saves already schedule indexing; use this for an explicit refresh and inspect progress with get_document_index_status.",
|
|
654
|
+
inputSchema: z2.object({ documentId: z2.string().min(1).describe("Document UUID returned by search_documents or list_documents; must be readable in the active scope.") })
|
|
620
655
|
}, wrapHandler(async ({ documentId }) => client.refreshDocumentIndex(documentId)));
|
|
621
656
|
server.registerPrompt("organize_workspace", {
|
|
622
657
|
description: "Plan safe document organization using DocsMint categories and folders.",
|
|
623
|
-
argsSchema:
|
|
624
|
-
objective:
|
|
625
|
-
language:
|
|
658
|
+
argsSchema: z2.object({
|
|
659
|
+
objective: z2.string(),
|
|
660
|
+
language: z2.string().optional()
|
|
626
661
|
})
|
|
627
662
|
}, ({ objective, language }) => ({
|
|
628
663
|
messages: [
|
|
@@ -637,9 +672,9 @@ function registerExtendedCapabilities(server, client, wrapHandler) {
|
|
|
637
672
|
}));
|
|
638
673
|
server.registerPrompt("research_workspace", {
|
|
639
674
|
description: "Research a question with hybrid search and GraphRAG while citing DocsMint document IDs.",
|
|
640
|
-
argsSchema:
|
|
641
|
-
question:
|
|
642
|
-
language:
|
|
675
|
+
argsSchema: z2.object({
|
|
676
|
+
question: z2.string(),
|
|
677
|
+
language: z2.string().optional()
|
|
643
678
|
})
|
|
644
679
|
}, ({ question, language }) => ({
|
|
645
680
|
messages: [
|
|
@@ -730,6 +765,10 @@ function sanitizeMcpRequestContext(context) {
|
|
|
730
765
|
function createMcpDocsClient(docsClient, requestContext) {
|
|
731
766
|
const context = sanitizeMcpRequestContext(requestContext);
|
|
732
767
|
return {
|
|
768
|
+
deleteDocument: (id) => docsClient.deleteDoc(id, context),
|
|
769
|
+
deleteFolder: (id) => docsClient.deleteFolder(id, context),
|
|
770
|
+
deleteCategory: (id) => docsClient.deleteCategory(id, context),
|
|
771
|
+
restoreDocumentVersion: (documentId, versionId) => docsClient.restoreVersion(documentId, versionId, context),
|
|
733
772
|
search: (params) => docsClient.search(params.query, {
|
|
734
773
|
folder: params.folder,
|
|
735
774
|
tags: params.tags?.join(","),
|
|
@@ -776,15 +815,15 @@ __export(exports_create_document, {
|
|
|
776
815
|
definition: () => definition,
|
|
777
816
|
handler: () => handler
|
|
778
817
|
});
|
|
779
|
-
import { z as
|
|
818
|
+
import { z as z3 } from "zod";
|
|
780
819
|
var definition = {
|
|
781
820
|
name: "create_document",
|
|
782
821
|
description: "Create a new document. Optionally provide initial markdown content and a folder ID.",
|
|
783
822
|
inputSchema: {
|
|
784
|
-
title:
|
|
785
|
-
content:
|
|
786
|
-
folderId:
|
|
787
|
-
categoryId:
|
|
823
|
+
title: z3.string().describe("Document title."),
|
|
824
|
+
content: z3.string().optional().describe("Initial markdown content for the document."),
|
|
825
|
+
folderId: z3.string().optional().describe("Optional folder ID to place the document in."),
|
|
826
|
+
categoryId: z3.string().optional().describe("Optional category ID. Category keys are always rebound to their configured category.")
|
|
788
827
|
}
|
|
789
828
|
};
|
|
790
829
|
var createHandler = (api) => async function createDocument(args) {
|
|
@@ -799,14 +838,14 @@ __export(exports_create_folder, {
|
|
|
799
838
|
definition: () => definition2,
|
|
800
839
|
handler: () => handler2
|
|
801
840
|
});
|
|
802
|
-
import { z as
|
|
841
|
+
import { z as z4 } from "zod";
|
|
803
842
|
var definition2 = {
|
|
804
843
|
name: "create_folder",
|
|
805
844
|
description: "Create a new folder, optionally nested under a parent folder.",
|
|
806
845
|
inputSchema: {
|
|
807
|
-
name:
|
|
808
|
-
parentId:
|
|
809
|
-
categoryId:
|
|
846
|
+
name: z4.string().describe("Folder name."),
|
|
847
|
+
parentId: z4.string().optional().describe("Optional parent folder ID for nesting."),
|
|
848
|
+
categoryId: z4.string().optional().describe("Optional category ID. Category keys are always rebound to their configured category.")
|
|
810
849
|
}
|
|
811
850
|
};
|
|
812
851
|
var createHandler2 = (api) => async function createFolder(args) {
|
|
@@ -821,14 +860,14 @@ __export(exports_create_snapshot, {
|
|
|
821
860
|
definition: () => definition3,
|
|
822
861
|
handler: () => handler3
|
|
823
862
|
});
|
|
824
|
-
import { z as
|
|
863
|
+
import { z as z5 } from "zod";
|
|
825
864
|
var definition3 = {
|
|
826
865
|
name: "create_snapshot",
|
|
827
866
|
description: "Create a named snapshot (labelled version) of a document from its current content.",
|
|
828
867
|
inputSchema: {
|
|
829
|
-
documentId:
|
|
830
|
-
label:
|
|
831
|
-
description:
|
|
868
|
+
documentId: z5.string().describe("Document ID to snapshot."),
|
|
869
|
+
label: z5.string().describe("Short label for the snapshot (e.g. 'v1.0-release')."),
|
|
870
|
+
description: z5.string().optional().describe("Optional longer description of the snapshot.")
|
|
832
871
|
}
|
|
833
872
|
};
|
|
834
873
|
var createHandler3 = (api) => async function createSnapshot(args) {
|
|
@@ -844,12 +883,12 @@ __export(exports_export_document, {
|
|
|
844
883
|
definition: () => definition4,
|
|
845
884
|
handler: () => handler4
|
|
846
885
|
});
|
|
847
|
-
import { z as
|
|
886
|
+
import { z as z6 } from "zod";
|
|
848
887
|
var definition4 = {
|
|
849
888
|
name: "export_document",
|
|
850
|
-
description: "
|
|
889
|
+
description: "Render one readable document as portable Markdown and return a markdown string in the response object. Does not modify the document or include its complete metadata; use get_document to inspect the editable document.",
|
|
851
890
|
inputSchema: {
|
|
852
|
-
id:
|
|
891
|
+
id: z6.string().describe("Document ID to export.")
|
|
853
892
|
}
|
|
854
893
|
};
|
|
855
894
|
var createHandler4 = (api) => async function exportDocument(args) {
|
|
@@ -864,12 +903,12 @@ __export(exports_get_document, {
|
|
|
864
903
|
definition: () => definition5,
|
|
865
904
|
handler: () => handler5
|
|
866
905
|
});
|
|
867
|
-
import { z as
|
|
906
|
+
import { z as z7 } from "zod";
|
|
868
907
|
var definition5 = {
|
|
869
908
|
name: "get_document",
|
|
870
|
-
description: "
|
|
909
|
+
description: "Read one document with its content, metadata, and tags before editing or citing it. Requires read access. Use export_document when you only need portable Markdown.",
|
|
871
910
|
inputSchema: {
|
|
872
|
-
id:
|
|
911
|
+
id: z7.string().describe("Document ID.")
|
|
873
912
|
}
|
|
874
913
|
};
|
|
875
914
|
var createHandler5 = (api) => async function getDocument(args) {
|
|
@@ -884,15 +923,15 @@ __export(exports_list_documents, {
|
|
|
884
923
|
definition: () => definition6,
|
|
885
924
|
handler: () => handler6
|
|
886
925
|
});
|
|
887
|
-
import { z as
|
|
926
|
+
import { z as z8 } from "zod";
|
|
888
927
|
var definition6 = {
|
|
889
928
|
name: "list_documents",
|
|
890
929
|
description: "List documents with pagination, optionally filtered by folder or tag.",
|
|
891
930
|
inputSchema: {
|
|
892
|
-
folderId:
|
|
893
|
-
tag:
|
|
894
|
-
page:
|
|
895
|
-
limit:
|
|
931
|
+
folderId: z8.string().optional().describe("Optional folder ID to filter by."),
|
|
932
|
+
tag: z8.string().optional().describe("Optional tag ID to filter by."),
|
|
933
|
+
page: z8.number().int().positive().optional().describe("Page number (1-indexed, default 1)."),
|
|
934
|
+
limit: z8.number().int().positive().max(100).optional().describe("Items per page (default 20, max 100).")
|
|
896
935
|
}
|
|
897
936
|
};
|
|
898
937
|
var createHandler6 = (api) => async function listDocuments(args) {
|
|
@@ -907,12 +946,12 @@ __export(exports_list_folders, {
|
|
|
907
946
|
definition: () => definition7,
|
|
908
947
|
handler: () => handler7
|
|
909
948
|
});
|
|
910
|
-
import { z as
|
|
949
|
+
import { z as z9 } from "zod";
|
|
911
950
|
var definition7 = {
|
|
912
951
|
name: "list_folders",
|
|
913
952
|
description: "List folders, optionally scoped to a parent folder. Returns a flat list of immediate children.",
|
|
914
953
|
inputSchema: {
|
|
915
|
-
parentId:
|
|
954
|
+
parentId: z9.string().optional().describe("Optional parent folder ID. Omit to list top-level (root) folders.")
|
|
916
955
|
}
|
|
917
956
|
};
|
|
918
957
|
var createHandler7 = (api) => async function listFolders(args) {
|
|
@@ -927,15 +966,15 @@ __export(exports_search, {
|
|
|
927
966
|
definition: () => definition8,
|
|
928
967
|
handler: () => handler8
|
|
929
968
|
});
|
|
930
|
-
import { z as
|
|
969
|
+
import { z as z10 } from "zod";
|
|
931
970
|
var definition8 = {
|
|
932
971
|
name: "search_documents",
|
|
933
972
|
description: "Hybrid search across documents (full-text + semantic). Supports filtering by folder and tags.",
|
|
934
973
|
inputSchema: {
|
|
935
|
-
query:
|
|
936
|
-
folder:
|
|
937
|
-
tags:
|
|
938
|
-
limit:
|
|
974
|
+
query: z10.string().describe("Search query string."),
|
|
975
|
+
folder: z10.string().optional().describe("Optional folder ID to scope the search to."),
|
|
976
|
+
tags: z10.array(z10.string()).optional().describe("Optional tag IDs to filter by."),
|
|
977
|
+
limit: z10.number().int().positive().optional().describe("Maximum number of results to return (default 20).")
|
|
939
978
|
}
|
|
940
979
|
};
|
|
941
980
|
var createHandler8 = (api) => async function searchDocuments(args) {
|
|
@@ -955,16 +994,16 @@ __export(exports_update_document, {
|
|
|
955
994
|
definition: () => definition9,
|
|
956
995
|
handler: () => handler9
|
|
957
996
|
});
|
|
958
|
-
import { z as
|
|
997
|
+
import { z as z11 } from "zod";
|
|
959
998
|
var definition9 = {
|
|
960
999
|
name: "update_document",
|
|
961
1000
|
description: "Update an existing document's title and/or content. The server creates a new version on each update.",
|
|
962
1001
|
inputSchema: {
|
|
963
|
-
id:
|
|
964
|
-
title:
|
|
965
|
-
content:
|
|
966
|
-
folderId:
|
|
967
|
-
categoryId:
|
|
1002
|
+
id: z11.string().describe("Document ID to update."),
|
|
1003
|
+
title: z11.string().optional().describe("New title for the document."),
|
|
1004
|
+
content: z11.string().optional().describe("New markdown content for the document."),
|
|
1005
|
+
folderId: z11.string().nullable().optional().describe("Move the document to a folder."),
|
|
1006
|
+
categoryId: z11.string().nullable().optional().describe("Move the document to a category. Category keys cannot escape their configured category.")
|
|
968
1007
|
}
|
|
969
1008
|
};
|
|
970
1009
|
var createHandler9 = (api) => async function updateDocument(args) {
|
|
@@ -980,13 +1019,13 @@ __export(exports_version_history, {
|
|
|
980
1019
|
definition: () => definition10,
|
|
981
1020
|
handler: () => handler10
|
|
982
1021
|
});
|
|
983
|
-
import { z as
|
|
1022
|
+
import { z as z12 } from "zod";
|
|
984
1023
|
var definition10 = {
|
|
985
1024
|
name: "get_version_history",
|
|
986
1025
|
description: "List the version history for a document. Optionally restrict to named snapshots.",
|
|
987
1026
|
inputSchema: {
|
|
988
|
-
documentId:
|
|
989
|
-
onlySnapshots:
|
|
1027
|
+
documentId: z12.string().describe("Document ID whose versions should be listed."),
|
|
1028
|
+
onlySnapshots: z12.boolean().optional().describe("When true, only return named snapshots (skip auto-saved revisions).")
|
|
990
1029
|
}
|
|
991
1030
|
};
|
|
992
1031
|
var createHandler10 = (api) => async function getVersionHistory(args) {
|
|
@@ -1028,7 +1067,12 @@ function wrapHandler(name, handler11) {
|
|
|
1028
1067
|
}
|
|
1029
1068
|
function registerDocsmintMcpCapabilities(server, client2) {
|
|
1030
1069
|
const register = (name, description, inputSchema, handler11) => {
|
|
1031
|
-
server.registerTool(name, { description, inputSchema:
|
|
1070
|
+
server.registerTool(name, { description, inputSchema: z13.object(inputSchema), annotations: {
|
|
1071
|
+
readOnlyHint: !["create_document", "update_document", "create_folder", "create_snapshot"].includes(name),
|
|
1072
|
+
destructiveHint: name === "update_document",
|
|
1073
|
+
idempotentHint: !["create_document", "update_document", "create_folder", "create_snapshot"].includes(name),
|
|
1074
|
+
openWorldHint: false
|
|
1075
|
+
} }, wrapHandler(name, handler11));
|
|
1032
1076
|
};
|
|
1033
1077
|
const tools = [
|
|
1034
1078
|
exports_search,
|
|
@@ -1046,9 +1090,10 @@ function registerDocsmintMcpCapabilities(server, client2) {
|
|
|
1046
1090
|
register(tool.definition.name, tool.definition.description, tool.definition.inputSchema, tool.createHandler(client2));
|
|
1047
1091
|
}
|
|
1048
1092
|
registerExtendedCapabilities(server, client2, (handler11) => wrapHandler("extended", handler11));
|
|
1093
|
+
registerLifecycleCapabilities(server, client2, (handler11) => wrapHandler("lifecycle", handler11));
|
|
1049
1094
|
}
|
|
1050
1095
|
function createDocsmintMcpServer(options = {}) {
|
|
1051
|
-
const server = new McpServer({ name: "docsmint", version: "0.8.
|
|
1096
|
+
const server = new McpServer({ name: "docsmint", version: "0.8.8" });
|
|
1052
1097
|
const client2 = options.docsClient ? createMcpDocsClient(options.docsClient, options.requestContext) : options.client ?? createMcpDocsClient(createDefaultDocsClient(), options.requestContext);
|
|
1053
1098
|
registerDocsmintMcpCapabilities(server, client2);
|
|
1054
1099
|
return server;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hiai-gg/docsmint",
|
|
3
3
|
"mcpName": "io.github.HiAi-gg/docsmint",
|
|
4
|
-
"version": "0.8.
|
|
4
|
+
"version": "0.8.8",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"browser": {
|
|
7
7
|
"./dist/backend-launcher.js": false,
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
"./dist/backend-account-runtime-cleanup.js": false
|
|
16
16
|
},
|
|
17
17
|
"license": "Apache-2.0",
|
|
18
|
-
"description": "
|
|
18
|
+
"description": "DocsMint SDK and CLI plus a self-hosted MCP stdio bridge that uses your API key. For DocsMint Cloud MCP, connect to https://docsmint.com/mcp.",
|
|
19
19
|
"repository": {
|
|
20
20
|
"type": "git",
|
|
21
21
|
"url": "https://github.com/HiAi-gg/docsmint"
|
|
@@ -25,7 +25,7 @@ import { registerSearch } from './commands/search.js';
|
|
|
25
25
|
import { registerSnapshot } from './commands/snapshot.js';
|
|
26
26
|
import { registerUpdate } from './commands/update.js';
|
|
27
27
|
|
|
28
|
-
const VERSION = '0.8.
|
|
28
|
+
const VERSION = '0.8.8';
|
|
29
29
|
|
|
30
30
|
const program = new Command();
|
|
31
31
|
program.name('docsmint').description('CLI for the DocsMint knowledge workspace').version(VERSION);
|
package/server.json
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
"id": "1249550690",
|
|
11
11
|
"subfolder": "packages/mcp-server"
|
|
12
12
|
},
|
|
13
|
-
"version": "0.8.
|
|
13
|
+
"version": "0.8.8",
|
|
14
14
|
"icons": [
|
|
15
15
|
{
|
|
16
16
|
"src": "https://raw.githubusercontent.com/HiAi-gg/docsmint/main/frontend/static/logo-dark.png",
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
"registryType": "npm",
|
|
31
31
|
"registryBaseUrl": "https://registry.npmjs.org",
|
|
32
32
|
"identifier": "@hiai-gg/docsmint",
|
|
33
|
-
"version": "0.8.
|
|
33
|
+
"version": "0.8.8",
|
|
34
34
|
"runtimeHint": "npx",
|
|
35
35
|
"transport": {
|
|
36
36
|
"type": "stdio"
|
|
@@ -44,12 +44,12 @@
|
|
|
44
44
|
"environmentVariables": [
|
|
45
45
|
{
|
|
46
46
|
"name": "HIAI_DOCS_URL",
|
|
47
|
-
"description": "Base URL of your running self-hosted DocsMint API. For
|
|
47
|
+
"description": "Base URL of your running self-hosted DocsMint REST API, for example http://localhost:50700. For Cloud MCP, use the Streamable HTTP remote below.",
|
|
48
48
|
"default": "http://localhost:50700"
|
|
49
49
|
},
|
|
50
50
|
{
|
|
51
51
|
"name": "HIAI_DOCS_API_KEY",
|
|
52
|
-
"description": "Create an API key in your self-hosted DocsMint browser UI. Prefer workspace-bound or category-scoped credentials.",
|
|
52
|
+
"description": "Create an API key in your self-hosted DocsMint browser UI. The stdio bridge uses it only with your own API; it does not install the Cloud OAuth server. Prefer workspace-bound or category-scoped credentials.",
|
|
53
53
|
"isRequired": true,
|
|
54
54
|
"isSecret": true
|
|
55
55
|
}
|
|
@@ -63,7 +63,7 @@
|
|
|
63
63
|
"headers": [
|
|
64
64
|
{
|
|
65
65
|
"name": "Authorization",
|
|
66
|
-
"description": "DocsMint Cloud
|
|
66
|
+
"description": "DocsMint Cloud remote at https://docsmint.com/mcp; no self-hosted server is required. Discovery advertises /oauth/authorize, /oauth/token, and active DCR at https://docsmint.com/oauth/register. Metadata supports the code response type, authorization_code grant only, no token-endpoint client authentication, and PKCE S256; CIMD is not part of the contract. Access tokens last one hour, have no refresh token, and are bound by browser consent to a workspace, optional category, and requested scopes. API-key clients can use Authorization: Bearer <key> with a workspace-bound or category-scoped credential created at https://docsmint.com/mcp/connect?source=mcp_registry. Credential management requires a browser session. For self-hosting, use the stdio package with your own API and API key; it does not install the Cloud OAuth server.",
|
|
67
67
|
"isRequired": true,
|
|
68
68
|
"isSecret": true
|
|
69
69
|
},
|
|
@@ -83,7 +83,7 @@
|
|
|
83
83
|
"licenseFile": "https://github.com/HiAi-gg/docsmint/blob/main/LICENSE",
|
|
84
84
|
"documentationUrl": "https://docsmint.com/mcp/connect?source=mcp_registry",
|
|
85
85
|
"catalog": {
|
|
86
|
-
"tools":
|
|
86
|
+
"tools": 21,
|
|
87
87
|
"prompts": 2,
|
|
88
88
|
"resources": 3
|
|
89
89
|
}
|