desearch-mcp-server 0.1.3 → 0.1.4
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/CHANGELOG.md +4 -0
- package/README.md +12 -2
- package/build/server.d.ts +1 -1
- package/build/server.js +2 -2
- package/build/tool-sources.d.ts +8 -15
- package/build/tool-sources.d.ts.map +1 -1
- package/build/tool-sources.js +7 -16
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
|
@@ -8,7 +8,7 @@ AI search, X search and web search for AI agents, plus page extraction and X dat
|
|
|
8
8
|
|
|
9
9
|
The Desearch MCP server includes the following tools:
|
|
10
10
|
|
|
11
|
-
- **AI Search** (`ai-search`): Performs AI Twitter and web searches with relevant links and summary. `tools` uses short source ids (`web`, `twitter`, `arxiv`, `wikipedia`, `
|
|
11
|
+
- **AI Search** (`ai-search`): Performs AI Twitter and web searches with relevant links and summary. `tools` uses short source ids (`web`, `twitter`, `arxiv`, `wikipedia`, `hackernews`, `reddit`). Older labels such as `Web Search`, `ArXiv Search`, `Wikipedia Search`, `Hacker News Search`, and `Reddit Search` are still accepted and sent as the short id. `youtube` is not accepted. Default is `["web", "twitter"]`.
|
|
12
12
|
- **X Search** (`x-search`): Tweet search on X. Arguments: `query` (required), `count` (optional, default 20). Sort stays Top. Optional filters: `user`, `start_date`, `end_date` (YYYY-MM-DD), `lang`, `verified`, `blue_verified`, `is_quote`, `is_video`, `is_image`, `min_retweets`, `min_replies`, `min_likes`.
|
|
13
13
|
- **Web Search** (`web-search`): SERP-style web search. Arguments: `query` (required), `start` (optional pagination offset).
|
|
14
14
|
- **Web Links Search** (`web-links-search`): Web link search. Arguments: `prompt` (required), `tools` (optional, only `web`, default `["web"]`; `Web Search` is accepted and rewritten to `web`), `count` (optional, 10–200). The links/web API rejects other sources, so they are not in the enum.
|
|
@@ -37,7 +37,7 @@ The full SDK method → endpoint → MCP tool map is in [docs/API_MCP_PARITY.md]
|
|
|
37
37
|
|
|
38
38
|
### NPM Installation
|
|
39
39
|
|
|
40
|
-
The package name is `desearch-mcp-server`. The
|
|
40
|
+
The package name is `desearch-mcp-server`. The current version is on [npm](https://www.npmjs.com/package/desearch-mcp-server). See [CHANGELOG.md](CHANGELOG.md) for release notes. The stdio entry is the `desearch-mcp-server` bin (`build/index.js`), which requires `DESEARCH_API_KEY`.
|
|
41
41
|
|
|
42
42
|
```bash
|
|
43
43
|
npm install -g desearch-mcp-server
|
|
@@ -67,6 +67,16 @@ Cursor or Claude can start that bin directly:
|
|
|
67
67
|
|
|
68
68
|
`command: "desearch-mcp-server"` (no `args`) is the same entry after the global install above.
|
|
69
69
|
|
|
70
|
+
### Gemini CLI
|
|
71
|
+
|
|
72
|
+
Install the extension from this repository. Gemini CLI asks for your Desearch API key (stored as a sensitive setting) and connects to the hosted server `https://mcp.desearch.ai/mcp`:
|
|
73
|
+
|
|
74
|
+
```bash
|
|
75
|
+
gemini extensions install https://github.com/Desearch-ai/mcp-desearch
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
To change the key later, run `gemini extensions config desearch`. AI agents such as Cline can follow [llms-install.md](llms-install.md) to set up the server.
|
|
79
|
+
|
|
70
80
|
### Using Smithery
|
|
71
81
|
|
|
72
82
|
To install the Desearch MCP server for Claude Desktop automatically via [Smithery](https://smithery.ai/servers/desearch/desearch):
|
package/build/server.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
|
|
2
2
|
export declare const SERVER_NAME = "Desearch";
|
|
3
|
-
export declare const SERVER_VERSION = "0.1.
|
|
3
|
+
export declare const SERVER_VERSION = "0.1.4";
|
|
4
4
|
interface XSearchPayload {
|
|
5
5
|
query: string;
|
|
6
6
|
sort?: "Top" | "Latest";
|
package/build/server.js
CHANGED
|
@@ -4,7 +4,7 @@ import DesearchImport from "desearch-js";
|
|
|
4
4
|
import { z } from "zod";
|
|
5
5
|
import { AI_SEARCH_TOOLS, WEB_LINK_TOOLS, toolIdSchema } from "./tool-sources.js";
|
|
6
6
|
export const SERVER_NAME = "Desearch";
|
|
7
|
-
export const SERVER_VERSION = "0.1.
|
|
7
|
+
export const SERVER_VERSION = "0.1.4";
|
|
8
8
|
// desearch-js 1.5 publishes a default class. Node16 resolution types that package
|
|
9
9
|
// as a module namespace, so the constructor is applied through a cast.
|
|
10
10
|
const Desearch = DesearchImport;
|
|
@@ -172,7 +172,7 @@ export function createDesearchMcpServer(apiKey, client) {
|
|
|
172
172
|
.array(toolIdSchema(AI_SEARCH_TOOLS))
|
|
173
173
|
.optional()
|
|
174
174
|
.default(["web", "twitter"])
|
|
175
|
-
.describe("Source ids sent to POST /desearch/ai/search.
|
|
175
|
+
.describe("Source ids sent to POST /desearch/ai/search. Short ids: 'web', 'twitter', 'arxiv', 'wikipedia', 'hackernews', 'reddit'. Legacy labels such as 'Web Search', 'ArXiv Search', 'Wikipedia Search', 'Hacker News Search', and 'Reddit Search' are rewritten to those ids. Example: ['web', 'twitter']."),
|
|
176
176
|
date_filter: z
|
|
177
177
|
.enum([
|
|
178
178
|
"PAST_24_HOURS",
|
package/build/tool-sources.d.ts
CHANGED
|
@@ -1,24 +1,17 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
/**
|
|
3
|
-
* Short source ids
|
|
3
|
+
* Short source ids for ai-search and web-links-search.
|
|
4
4
|
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* are the previous ai-search schema. They are accepted here and rewritten to
|
|
9
|
-
* the short id before the Desearch call.
|
|
5
|
+
* Display labels such as "Web Search" are the previous ai-search schema.
|
|
6
|
+
* They are accepted here and rewritten to the short id before the Desearch call.
|
|
7
|
+
* "Youtube Search" is not rewritten; `youtube` is not an ai-search tool id.
|
|
10
8
|
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
* desearch-js sources under display labels. Those stay, spelled as short ids.
|
|
15
|
-
* PR #13 did not see a 422 for this route.
|
|
16
|
-
* - `WebToolEnum` (`POST /desearch/ai/search/links/web`): `web` only. The other
|
|
17
|
-
* short ids 422 (`supported tools are Web Search`). `WEB_LINK_TOOLS` is
|
|
18
|
-
* `["web"]` so the MCP enum does not offer ids the route rejects.
|
|
9
|
+
* - `AI_SEARCH_TOOLS` (`POST /desearch/ai/search`): `web`, `twitter`, `arxiv`,
|
|
10
|
+
* `wikipedia`, `hackernews`, `reddit`. Same order as before, without `youtube`.
|
|
11
|
+
* - `WEB_LINK_TOOLS` (`POST /desearch/ai/search/links/web`): `web` only.
|
|
19
12
|
* `"Web Search"` still rewrites to `web`.
|
|
20
13
|
*/
|
|
21
|
-
export declare const AI_SEARCH_TOOLS: readonly ["web", "twitter", "arxiv", "wikipedia", "
|
|
14
|
+
export declare const AI_SEARCH_TOOLS: readonly ["web", "twitter", "arxiv", "wikipedia", "hackernews", "reddit"];
|
|
22
15
|
export declare const WEB_LINK_TOOLS: readonly ["web"];
|
|
23
16
|
/** Previous ai-search labels. Not advertised in the JSON Schema enum. */
|
|
24
17
|
export declare const LEGACY_DISPLAY_TO_ID: Readonly<Record<string, string>>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tool-sources.d.ts","sourceRoot":"","sources":["../tool-sources.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB
|
|
1
|
+
{"version":3,"file":"tool-sources.d.ts","sourceRoot":"","sources":["../tool-sources.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,eAAe,2EAOlB,CAAC;AAEX,eAAO,MAAM,cAAc,kBAAmB,CAAC;AAE/C,yEAAyE;AACzE,eAAO,MAAM,oBAAoB,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAOjE,CAAC;AAEF,wBAAgB,eAAe,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAErD;AAED,KAAK,WAAW,GAAG,SAAS,CAAC,MAAM,EAAE,GAAG,MAAM,EAAE,CAAC,CAAC;AAElD;;;GAGG;AACH,wBAAgB,YAAY,CAAC,CAAC,SAAS,WAAW,EAAE,GAAG,EAAE,CAAC,mEAKzD"}
|
package/build/tool-sources.js
CHANGED
|
@@ -1,21 +1,14 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
/**
|
|
3
|
-
* Short source ids
|
|
3
|
+
* Short source ids for ai-search and web-links-search.
|
|
4
4
|
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* are the previous ai-search schema. They are accepted here and rewritten to
|
|
9
|
-
* the short id before the Desearch call.
|
|
5
|
+
* Display labels such as "Web Search" are the previous ai-search schema.
|
|
6
|
+
* They are accepted here and rewritten to the short id before the Desearch call.
|
|
7
|
+
* "Youtube Search" is not rewritten; `youtube` is not an ai-search tool id.
|
|
10
8
|
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
* desearch-js sources under display labels. Those stay, spelled as short ids.
|
|
15
|
-
* PR #13 did not see a 422 for this route.
|
|
16
|
-
* - `WebToolEnum` (`POST /desearch/ai/search/links/web`): `web` only. The other
|
|
17
|
-
* short ids 422 (`supported tools are Web Search`). `WEB_LINK_TOOLS` is
|
|
18
|
-
* `["web"]` so the MCP enum does not offer ids the route rejects.
|
|
9
|
+
* - `AI_SEARCH_TOOLS` (`POST /desearch/ai/search`): `web`, `twitter`, `arxiv`,
|
|
10
|
+
* `wikipedia`, `hackernews`, `reddit`. Same order as before, without `youtube`.
|
|
11
|
+
* - `WEB_LINK_TOOLS` (`POST /desearch/ai/search/links/web`): `web` only.
|
|
19
12
|
* `"Web Search"` still rewrites to `web`.
|
|
20
13
|
*/
|
|
21
14
|
export const AI_SEARCH_TOOLS = [
|
|
@@ -23,7 +16,6 @@ export const AI_SEARCH_TOOLS = [
|
|
|
23
16
|
"twitter",
|
|
24
17
|
"arxiv",
|
|
25
18
|
"wikipedia",
|
|
26
|
-
"youtube",
|
|
27
19
|
"hackernews",
|
|
28
20
|
"reddit",
|
|
29
21
|
];
|
|
@@ -34,7 +26,6 @@ export const LEGACY_DISPLAY_TO_ID = {
|
|
|
34
26
|
"Twitter Search": "twitter",
|
|
35
27
|
"ArXiv Search": "arxiv",
|
|
36
28
|
"Wikipedia Search": "wikipedia",
|
|
37
|
-
"Youtube Search": "youtube",
|
|
38
29
|
"Hacker News Search": "hackernews",
|
|
39
30
|
"Reddit Search": "reddit",
|
|
40
31
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "desearch-mcp-server",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.4",
|
|
4
4
|
"mcpName": "io.github.Desearch-ai/mcp-desearch",
|
|
5
5
|
"description": "AI search, X search and web search for AI agents, plus page extraction and X data tools. Bring your own Desearch API key.",
|
|
6
6
|
"license": "MIT",
|