Commit Graph

8 Commits

Author SHA1 Message Date
cliffhall
20527e4175 Updated doc in all tools 2025-12-13 15:55:07 -05:00
cliffhall
7b8592538f Updated doc in all tools 2025-12-13 15:52:32 -05:00
cliffhall
0ba86f8d4f Updated doc in echo.ts 2025-12-13 15:48:13 -05:00
cliffhall
2ce87b168c [WIP] Refactor everything server to be more modular and use recommended APIs.
* Added git-tiny-image.ts
  - registers a tool that returns a tiny MCP logo

* In all other tools, updated function docs
2025-12-09 10:17:37 -05:00
cliffhall
1df8623bcc [WIP] Refactor everything server to be more modular and use recommended APIs.
Added long-running-operation tool and improved comments in all tools

* Updated architecture.md

* In tools/
  - add.ts
  - echo.ts
  - toggle-logging.ts
  - toggle-subscriber-updates.ts
    - Add better function and inline docs

* Added tools/long-running-operation.ts
  - similar implementation as in everything v1

* In tools/index.ts
  - import registerLongRunningOperationTool
  - in registerTools
    - registerLongRunningOperationTool
2025-12-08 17:55:04 -05:00
cliffhall
eee9866ebb [WIP] Refactor everything server to be more modular and use recommended APIs.
* Updated architecture.md

* Refactor / renamed all addXPrompt, addXTool, and addXResource functions to registerX...

* Added the add tool
2025-12-05 18:43:36 -05:00
cliffhall
1c64b36c78 [WIP] Refactor everything server to be more modular and use recommended APIs.
* Adding static resources, move server instructions to
the new docs folder, and add code formatting

* Add docs folder

* Add docs/architecture.md which describes the architecture of the project thus far.

* Refactor moved instructions.md to docs/server-instructions.md

* Add resources/static.ts
  - in addStaticResources()
    - read the file entries from the docs folder
    - register each file as a resource (no template), with a readResource function that reads the file and returns it in a contents block with the appropriate mime type and contents
  - getMimeType helper function gets the mime type for a filename
  - readSafe helper function reads the file synchronously as utf-8 or returns an error string

* Add resources/index.ts
  - import addStaticResources
  - export registerResources function
  - in registerResources()
    - call addStaticResources

* In package.json
  - add prettier devDependency
  - add prettier:check script
  - add prettier:fix script
  - in build script, copy docs folder to dist

* All other changes were prettier formatting
2025-12-05 13:26:08 -05:00
cliffhall
5de886ca63 [WIP] Refactor everything server to be more modular and use recommended APIs
In src/everything:

* Refactor / move streamableHttp.ts, sse.ts, and stdio.ts to transports/

* Move everything.ts to server/ for reference

* Add server/index.js
  - exports the createServer function
  - import registerTools from tools/index.js
  - in createServer()
    - read instructions.md and include in ServerOptions for McpServer constructor
    - construct McpServer instead of Server
    - call registerTools, passing server

* Add tools/echo.ts
  - define EchoSchema
  - define tool config
  - export addToolEcho function
  - in addToolEcho()
    - register handler for Echo tool

* Add tools/index.ts
  - import addToolEcho
  - export registerTools function
  - in registerTools()
    - call addToolEcho
2025-12-03 17:36:47 -05:00