mycelium-api 8.3.1-rc.1

Provide API ports to the mycelium project.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use crate::rpc::types::{success_response, JsonRpcRequest, JsonRpcResponse};
use serde_json::json;

pub(crate) fn handle_initialize(req: &JsonRpcRequest) -> JsonRpcResponse {
    success_response(
        req.id.clone(),
        json!({
            "protocolVersion": "2025-03-26",
            "capabilities": {
                "tools": {}
            },
            "serverInfo": {
                "name": "mycelium",
                "version": env!("CARGO_PKG_VERSION")
            }
        }),
    )
}