"use strict";
/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 */
Object.defineProperty(exports, "__esModule", { value: true });
exports.createMCPServer = createMCPServer;
const mcp_js_1 = require("@modelcontextprotocol/sdk/server/mcp.js");
const core_js_1 = require("../core.js");
const prompts_js_1 = require("./prompts.js");
const resources_js_1 = require("./resources.js");
const server_extensions_js_1 = require("./server.extensions.js");
const tools_js_1 = require("./tools.js");
const generalPartition_js_1 = require("./tools/generalPartition.js");
function createMCPServer(deps) {
    const server = new mcp_js_1.McpServer({
        name: "UnstructuredClient",
        version: "0.31.0",
    });
    const client = new core_js_1.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 = (0, tools_js_1.createRegisterTool)(deps.logger, server, client, scopes, allowedTools);
    const resource = (0, resources_js_1.createRegisterResource)(deps.logger, server, client, scopes);
    const resourceTemplate = (0, resources_js_1.createRegisterResourceTemplate)(deps.logger, server, client, scopes);
    const prompt = (0, prompts_js_1.createRegisterPrompt)(deps.logger, server, client, scopes);
    const register = { tool, resource, resourceTemplate, prompt };
    void register; // suppress unused warnings
    tool(generalPartition_js_1.tool$generalPartition);
    (0, server_extensions_js_1.registerMCPExtensions)(register);
    return server;
}
//# sourceMappingURL=server.js.map