Commit graph

108 commits

Author SHA1 Message Date
jokemanfire
d24d80a094
chore: add dependbot for check dep (#204)
Signed-off-by: jokemanfire <hu.dingyang@zte.com.cn>
2025-05-21 11:09:01 +08:00
z9rtm
08c933a095
ci: revert badge (#202)
Co-authored-by: GCOV Github Badge <build@github.com>
2025-05-21 09:19:25 +08:00
4t145
076dc2c2cd
feat: better http server support (#199)
* feat: better http server support

1. allow user get extensions in tool call.
2. allow user serve sse service without initialization.

* fix: fix document test
2025-05-19 18:49:18 +08:00
jokemanfire
c1c4c9a0c9
doc: use hierarchical readme for publishing (#198) 2025-05-19 13:15:49 +08:00
4t145
a3b42c4a83
fix: sse endpoint build follow js's new URL(url, base) (#197)
* fix: sse endpoint build follow js's `new URL(url, base)`

* fix: fix feature denpencies
2025-05-19 13:09:00 +08:00
jokemanfire
752b4388a3
ci: update node version (#194)
fix node version

Signed-off-by: jokemanfire <hu.dingyang@zte.com.cn>
2025-05-19 11:11:51 +08:00
4t145
817e62d895
feat: throw initialize error detail (#192) 2025-05-19 09:41:56 +08:00
z9rtm
4dc0cad499
Ci/coverage badge (#191)
* ci: coverage badge
2025-05-19 09:07:01 +08:00
4t145
35282ee34c
feat: sse client optionally skip the endpoint event (#187) 2025-05-18 18:55:02 +08:00
4t145
c1e282e50d
fix: more friendly interface to get service error (#190) 2025-05-18 18:54:44 +08:00
Humberto Yusta Gómez
64995cc40c
fix: cleanup zombie processes for child process client (#156)
* feat(client): cleanup of zombie processes in child process client

Using process wrap library, Process Group for Unix and Job Object for Windows

* fix: install extra dep based on feature, update examples take owned command

Install process-wrap if transport-child-process feature is enabled. Update examples to take ownership
of the command instead of mutable reference

* fix: update other examples, comments and readme to take ownership of command

Updated more examples, comments and readme to take command instead of mutable ref.
Also small fix in cargo toml of example to use local path.

* refactor: add configure command ext

Added configure command ext to tokio process command so that
you can use .configure() to use inline commands for mcp stdio client.
Added warning if start kill process fails
2025-05-18 18:38:47 +08:00
Abhay Agarwal
68ddea3ad5
feat(server): add annotation to tool macro (#184)
skip serializing the tool annotations if none, fixes mcp inspector
2025-05-18 16:04:58 +08:00
4t145
5e4e77efa5
refactor: fix error introduced by merge, and reorganize feature (#185) 2025-05-18 14:15:41 +08:00
4t145
9a771fb157
refactor: Transport trait and worker transport, and streamable http client with those new features. (#167)
* refactor: a transport trait and streamable http client

* test: test with js streamable http server

* refactor: separate sse stream connection

* fix(test): streamable http client test with js

* fix(test): wait longer time for js server startup
2025-05-17 23:53:38 +08:00
jokemanfire
01eedb7770
fix(schemar): use self-defined settings (#180)
Ignores fields that are not defined in the spec file.

Signed-off-by: jokemanfire <hu.dingyang@zte.com.cn>
2025-05-16 14:40:28 +08:00
高庆丰
614d974d8d
example: Add named pipe example (#181) 2025-05-16 10:40:03 +08:00
Stanley Horwood
e9a5ae9901
feat(model): add json schema generation support for all model types (#176)
* feat(model): add json schema generation support for all model types

This commit adds JSON Schema support for all model types by implementing
`schemars::JsonSchema` trait. The feature is gated behind the new
`schemars` feature flag. This enables automatic schema generation for
API documentation and validation purposes. Added tests to verify schema
generation for client and server JSON-RPC messages.

* fix(model): add manual json schema implementation for `NumberOrString`

This commit adds a manual implementation of `JsonSchema` trait for the
`NumberOrString` enum to properly represent its union type nature in
JSON Schema. The schema now correctly specifies that the type can be
either a number or a string using the `oneOf` validation keyword.

* fix(model): skip extensions field in json schema generation

The `Extensions` type was incorrectly included in JSON schema
generation, which could lead to confusing API documentation. This commit
adds `#[schemars(skip)]` attribute to all `extensions` fields in request
and notification structs, and removes the manual `JsonSchema`
implementation for the `Extensions` type since it's an internal
implementation detail that shouldn't be exposed in the schema.
2025-05-15 23:56:31 +08:00
Jonathan Hendler
5d92061ece
feat(openapi): add OpenAPI v3 compatibility and test for nullable field schema workaround (#135) (#137) 2025-05-14 14:06:59 +08:00
Aaron
030b6f0858
fix(transport-sse-server): cleanup on connection drop (#165) 2025-05-12 14:15:34 +08:00
jokemanfire
6de444c62f
feat(examples): Add func call support (#168)
Some works about simple-chat.
1. fix some bugs.
2. add func call optional.

Signed-off-by: jokemanfire <hu.dingyang@zte.com.cn>
2025-05-12 13:52:57 +08:00
4t145
787cc015b7
feat(extension): extract http request part into rmcp extension (#163)
* feat(extension): extract http request part into rmcp extension

* perf(extension): insert extension from one entrypoint
2025-05-09 10:36:52 +08:00
Dennis Kawurek
546490a95e
fix: build errors for WASI target (#151) 2025-05-09 01:51:16 +08:00
4t145
57e14c56e8
feat(transport): support streamable http server (#152)
* feat(transport): support streamable http server

* refactor(transport): add common module for shared transport utilities

* perf(tracing): add more log for streamable http session

* fix(test): fix port conflict in test with js

* fix(transport): fix id generating and session management

1. cancel when deleting
2. use `wrapping` and `saturating` correctly

* chore(naming): rename sse server to streamable http server
2025-05-08 13:57:51 +08:00
jokemanfire
0847c17fa1
feat: add clippy config (#162)
Signed-off-by: jokemanfire <hu.dingyang@zte.com.cn>
2025-05-08 10:15:17 +08:00
Andrew Culberson
6c2e6e22ee
feat(oauth): fixes + cache client credentials (#157)
credentials optimize
2025-05-08 09:18:35 +08:00
Mauro Sardara
52c0651158
feat: allow use of reqwest without ring provider (#155)
Signed-off-by: Mauro Sardara <msardara@cisco.com>
2025-05-08 02:58:03 +08:00
4t145
09474d4769
fix(test): skip serialize tool's annotation if empty (#160)
* fix(test): skip serialize tool's annotation if empty

1. skip serialize tool's annotation if empty
2. close js server and client when close

* fix(test): fix test with js, don't close too early
2025-05-07 15:22:24 +08:00
jokemanfire
afb8a905e5
chore: add oauth2 support (#130)
1.add oauth2 server and client example
2.add oauth2 impl in sse
3.add auth doc 
Signed-off-by: jokemanfire <hu.dingyang@zte.com.cn>
2025-04-29 17:52:59 +08:00
Paul Ellenbogen
b1542a6153
fix: fix resource leak (#136)
When a running service is dropped, its connections should be closed and its resources should be
cleaned up.

This changes the default from leaving services running to closing them. Library users who want
their services to remain running should call `waiting` on their running service, in a new task
where necessary.

Co-authored-by: Paul Ellenbogen <pe5@cs.princeton.edu>
2025-04-28 17:56:20 +08:00
jokemanfire
5e4d447b32
chore: make cli command in simple-chat (#145)
add config,chat,help command
2025-04-27 09:10:51 +08:00
Eucalypt
6c2c02454d
chore: disable unix_socket example on windows (#146) 2025-04-26 14:27:15 +08:00
jokemanfire
18346b94e4
fix(rmcp-macros): fix extract_doc_line code (#142)
Signed-off-by: jokemanfire <hu.dingyang@zte.com.cn>
2025-04-20 11:00:59 +08:00
jokemanfire
b6fabc8836
chore: make proxy in simple-chat configure (#134)
and remove some prints and some useless codes

Signed-off-by: jokemanfire <hu.dingyang@zte.com.cn>
2025-04-20 11:00:47 +08:00
Sandipsinh Dilipsinh Rathod
3a97917cd7
feat(rmcp-macro): generate description from docs (#141)
* feat: generate description from docs

* fix logic to extract doc

* fmt

* chore: undo unnecessary changes in `Cargo.toml`

* chore: undo unnecessary changes in `Cargo.toml`

* chore: remove unnecessary code in tests

* create `extract_doc_line`

* fmt

* make sure the string is not empty

* avoid multilayer nesting

* fmt
2025-04-18 10:56:16 +08:00
z9rtm
9d6f9a2e0d
ci: security (#133)
* ci: add security audit job to workflow
2025-04-15 09:10:04 +08:00
jokemanfire
04a0a2cefb
docs: fix doc in simple-chat (#129) 2025-04-14 17:22:45 +08:00
Nora
9fc1cc0e0e
chore: remove un-used tower.rs (#125)
Signed-off-by: nora-coder-dot <nora6677@gmail.com>
Co-authored-by: nora-coder-dot <nora6677@gmail.com>
2025-04-11 16:11:28 +08:00
Ofer Affias
82239581ed
docs: fix typo and clarify instructions (#124) 2025-04-11 09:05:48 +08:00
Luke Francl
dffae27cf0
docs: update calculator example description (#115)
The example in the README uses "sum" for both `sum` and `sub`. I changed it to "difference". For consistency, I also updated the example code to use the same term.
2025-04-10 20:04:15 +08:00
jokemanfire
19e6d4596c
docs: fix the url (#120)
Signed-off-by: jokemanfire <hu.dingyang@zte.com.cn>
2025-04-10 17:16:09 +08:00
jokemanfire
2125698fdc
docs: add a simple chat client for example (#119)
1. optimize the readme in root
2. add example

Signed-off-by: jokemanfire <hu.dingyang@zte.com.cn>
2025-04-10 16:52:25 +08:00
4t145
31da5ff02d
fix(handler): do call handler methods when initialize server (#118) 2025-04-10 15:06:45 +08:00
Rik Huijzer
d0962ec9ee
docs: add an overview to rmcp/src/lib.rs (#116) 2025-04-10 09:11:35 +08:00
Rik Huijzer
1fc5be641f
ci: harden release action (#113) 2025-04-10 09:07:53 +08:00
Rik Huijzer
583a513448
fix: fix 2 cargo warnings (#112)
* fix: fix 3 cargo warnings

* revert `version = "1.0"` removal
2025-04-09 18:09:33 +08:00
Ruangyot Nanchiang
feb224c9aa
Fix typo for Claude desktop config file path correction and add more example for Windows, Linux, and MacOS (#107)
* fix(typo): claude desktop config file path correction
2025-04-09 10:50:26 +08:00
jokemanfire
7ae2728c54
fix(macros): add error deal (#109)
1.Check whether the parameters include aggregated parameters and individual parameters
2.Check if the toolbox attribute is default

Signed-off-by: jokemanfire <hu.dingyang@zte.com.cn>
2025-04-09 10:15:33 +08:00
z9rtm
a1112bcdfe
ci: add code coverage job to CI workflow (#111)
add code coverage job
2025-04-09 08:55:57 +08:00
Rik Huijzer
fdfb5274e8
docs: give macOS link and clarify missing UI (#110)
fix doc in examples/README.md.
2025-04-09 08:55:07 +08:00
Eitan Yarmush
6a423048fa
feat: extensions to context (#102) 2025-04-08 10:01:17 +08:00