refactor: finish MCP SDK v2 migration
This commit is contained in:
parent
a76e3a7691
commit
f94cb38b0b
1 changed files with 684 additions and 540 deletions
|
|
@ -1,5 +1,7 @@
|
|||
import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
|
||||
import type { ReadResourceResult } from "@modelcontextprotocol/sdk/types.js";
|
||||
import {
|
||||
McpServer,
|
||||
type ReadResourceResult,
|
||||
} from "@modelcontextprotocol/server";
|
||||
import fs from "node:fs/promises";
|
||||
import path from "node:path";
|
||||
import { z } from "zod";
|
||||
|
|
@ -178,8 +180,8 @@ export function createServer(): McpServer {
|
|||
title: "Get Cohort Retention Data",
|
||||
description:
|
||||
"Returns cohort retention heatmap data showing customer retention over time by signup month",
|
||||
inputSchema: GetCohortDataInputSchema.shape,
|
||||
outputSchema: CohortDataSchema.shape,
|
||||
inputSchema: GetCohortDataInputSchema,
|
||||
outputSchema: CohortDataSchema,
|
||||
_meta: { ui: { resourceUri } },
|
||||
},
|
||||
async ({ metric, periodType, cohortCount, maxPeriods }) => {
|
||||
|
|
|
|||
Loading…
Reference in a new issue