/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 */
import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
import { UnstructuredClientCore } from "../core.js";
import { createRegisterPrompt } from "./prompts.js";
import { createRegisterResource, createRegisterResourceTemplate, } from "./resources.js";
import { registerMCPExtensions } from "./server.extensions.js";
import { createRegisterTool } from "./tools.js";
import { tool$generalPartition } from "./tools/generalPartition.js";
export function createMCPServer(deps) {
    const server = new McpServer({
        name: "UnstructuredClient",
        version: "0.31.0",
    });
    const client = new UnstructuredClientCore({
        security: deps.security,
        serverURL: deps.serverURL,
        server: deps.server,
    });
    const scopes = new Set(deps.scopes);
    const allowedTools = deps.allowedTools && new Set(deps.allowedTools);
    const tool = createRegisterTool(deps.logger, server, client, scopes, allowedTools);
    const resource = createRegisterResource(deps.logger, server, client, scopes);
    const resourceTemplate = createRegisterResourceTemplate(deps.logger, server, client, scopes);
    const prompt = createRegisterPrompt(deps.logger, server, client, scopes);
    const register = { tool, resource, resourceTemplate, prompt };
    void register; // suppress unused warnings
    tool(tool$generalPartition);
    registerMCPExtensions(register);
    return server;
}
//# sourceMappingURL=server.js.map