@maviapi/mcp 0.2.0 → 0.2.2

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 CHANGED
@@ -16,6 +16,26 @@ Agents are bad at the web. Browsing is slow, burns tokens on raw HTML, and stall
16
16
 
17
17
  ## Install
18
18
 
19
+ ### Hosted: paste a URL, sign in
20
+
21
+ The same tools are hosted at **`https://mcp.maviapi.com/mcp`**, so nothing needs installing. In Claude or ChatGPT, add it as a custom connector and sign in to maviapi; calls use your plan's credits and the connection shows up on your [keys page](https://maviapi.com/dashboard/keys). Coding tools take the URL too:
22
+
23
+ ```bash
24
+ claude mcp add --transport http maviapi https://mcp.maviapi.com/mcp
25
+ ```
26
+
27
+ To try it without an account, connect to `https://mcp.maviapi.com/demo` (search and call on the shared demo key, no builds). More clients: [maviapi.com/docs#mcp](https://maviapi.com/docs#mcp).
28
+
29
+ The rest of this section runs the server locally from npm.
30
+
31
+ ### Gemini CLI
32
+
33
+ ```bash
34
+ gemini extensions install https://github.com/kuzenlabs/maviapi-mcp
35
+ ```
36
+
37
+ The extension connects to the hosted server and signs you in to maviapi the first time a tool runs.
38
+
19
39
  ### Claude Code
20
40
 
21
41
  Install it as a plugin from this repo's marketplace:
package/dist/config.js CHANGED
@@ -1,4 +1,4 @@
1
- export const VERSION = "0.2.0";
1
+ export const VERSION = "0.2.2";
2
2
  export const DEFAULT_BASE_URL = "https://api.maviapi.com";
3
3
  export const SITE_URL = "https://maviapi.com";
4
4
  /**
package/dist/server.js CHANGED
@@ -9,6 +9,13 @@ If no API covers the site you need, create_api builds one (about half an hour; f
9
9
  If an API exists but lacks an endpoint, or you need one to behave differently, request_endpoint adds one: preview it, let the user agree, start it with confirm: true, follow it with get_build_status (wait_seconds), try it with call_draft, and publish_request when the user wants it live.
10
10
  If an endpoint is simply broken (it fails, comes back empty, or repeats the same page), report_endpoint_issue with the params of the failing call: maviapi replays it and checks the endpoint itself. A fault its own check confirms is repaired in place; the rest are read by a person.
11
11
  Starting a build and publishing change things for the user: do them when the user asked, not on your own.`;
12
+ /**
13
+ * App directories (Claude's among them) read a tool's display name from
14
+ * annotations.title, so each tool carries its title there too.
15
+ */
16
+ export function withAnnotationTitles(tools) {
17
+ return tools.map((tool) => tool.title && !tool.annotations?.title ? { ...tool, annotations: { title: tool.title, ...tool.annotations } } : tool);
18
+ }
12
19
  /**
13
20
  * The tool list is computed at request time (MAVIAPI_TOOLS adds one typed tool
14
21
  * per endpoint, read from the live catalog), so the handlers are registered on
@@ -18,7 +25,7 @@ Starting a build and publishing change things for the user: do them when the use
18
25
  export function createServer(config, fetchImpl) {
19
26
  const toolset = new Toolset(new MaviapiClient(config, fetchImpl));
20
27
  const mcp = new McpServer({ name: "maviapi", title: "maviapi", version: VERSION, websiteUrl: "https://maviapi.com" }, { capabilities: { tools: {} }, instructions: INSTRUCTIONS });
21
- mcp.server.setRequestHandler(ListToolsRequestSchema, async () => ({ tools: await toolset.list() }));
28
+ mcp.server.setRequestHandler(ListToolsRequestSchema, async () => ({ tools: withAnnotationTitles(await toolset.list()) }));
22
29
  mcp.server.setRequestHandler(CallToolRequestSchema, (request) => toolset.call(request.params.name, request.params.arguments ?? {}));
23
30
  return mcp;
24
31
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@maviapi/mcp",
3
- "version": "0.2.0",
3
+ "version": "0.2.2",
4
4
  "description": "MCP server that gives AI agents live, structured JSON from websites with no official API (Booking.com, Airbnb, Tripadvisor, Kiwi.com, Hepsiburada and more), through self-repairing maviapi endpoints.",
5
5
  "mcpName": "io.github.kuzenlabs/maviapi-mcp",
6
6
  "type": "module",