Skip to main content
Glama
basementstudio

MCP DOS - Classic DOS Gaming Server

close-app

Shut down a running MCP DOS server by specifying the port. Use this to resolve errors when starting a new server for classic DOS games like DOOM or Tetris.

Instructions

Close an existing running mcp-dos server. You can use this tool if you are getting erros when starting a new server.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
portYesThe port of the app to close.

Implementation Reference

  • The main handler function that executes the tool logic: closes the running MCP-DOS server on the given port by fetching its /close endpoint and returns a success or error message.
    export default async function closeApp({ port }: InferSchema<typeof schema>) { try { const response = await fetch(`http://localhost:${port}/close`, { method: "GET", }); const data = await response.text(); return { content: [ { type: "text", text: `Closed server on port ${port}`, }, { type: "text", text: data, } ], } } catch (error) { return { content: [ { type: "text", text: `Error closing server on port ${port}: ${error}`, }, ], } } }
  • Input schema using Zod for validating the 'port' parameter.
    export const schema = { port: z.number().describe("The port of the app to close."), };
  • Metadata defining the tool's name, description, and annotations for MCP registration.
    export const metadata = { name: "close-app", description: "Close an existing running mcp-dos server. You can use this tool if you are getting erros when starting a new server.", annotations: { title: "Close app", readOnlyHint: true, destructiveHint: true, idempotentHint: true, }, };

Other Tools

Related Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/basementstudio/mcp-dos'

If you have feedback or need assistance with the MCP directory API, please join our Discord server