/**
* 👋 Welcome to your Smithery project!
* To run your server, run "npm run dev"
*
* You might find these resources useful:
*
* 🧑💻 MCP's TypeScript SDK (helps you define your server)
* https://github.com/modelcontextprotocol/typescript-sdk
*
* 📝 smithery.yaml (defines user-level config, like settings or API keys)
* https://smithery.ai/docs/build/project-config/smithery-yaml
*
* 💻 smithery CLI (run "npx @smithery/cli dev" or explore other commands below)
* https://smithery.ai/docs/concepts/cli
*/
import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js"
import { z } from "zod"
import { ContentReader } from "./utils/contentReader.js"
import { registerTools } from "./tools/index.js"
// Optional: If you have user-level config, define it here
// This should map to the config in your smithery.yaml file
export const configSchema = z.object({
debug: z.boolean().default(false).describe("Enable debug logging"),
})
export default function createServer({
config,
}: {
config: z.infer<typeof configSchema> // Define your config in smithery.yaml
}) {
const server = new McpServer({
name: "Writer MCP",
version: "1.0.0",
description: "A comprehensive suite of tools for technical marketing content creation, optimization, and product positioning based on Open Strategy Partners' proven methodologies.",
})
const contentReader = new ContentReader()
registerTools(server, contentReader)
return server.server
}