ZIm/crates/context_server
Bennet Bo Fenner 95d78ff8d5
context server: Make requests type safe (#32254)
This changes the context server crate so that the input/output for a
request are encoded at the type level, similar to how it is done for LSP
requests.

This also makes it easier to write tests that mock context servers, e.g.
you can write something like this now when using the `test-support`
feature of the `context-server` crate:

```rust
create_fake_transport("mcp-1", cx.background_executor())
    .on_request::<context_server::types::request::PromptsList>(|_params| {
        PromptsListResponse {
            prompts: vec![/* some prompts */],
            ..
        }
    })
```

Release Notes:

- N/A
2025-06-06 17:47:21 +02:00
..
src context server: Make requests type safe (#32254) 2025-06-06 17:47:21 +02:00
Cargo.toml context server: Make requests type safe (#32254) 2025-06-06 17:47:21 +02:00
LICENSE-GPL Factor tool definitions out of assistant (#21189) 2024-11-25 18:26:34 -05:00