Skip to content

Commit 97d9bc1

Browse files
authored
Merge pull request #32 from 0xeb/feature/replace-tiny-process-lib
Replace tiny-process-library with SDK process code (CreateProcessW)
2 parents 84e5d99 + 333c067 commit 97d9bc1

File tree

75 files changed

+9172
-703
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

75 files changed

+9172
-703
lines changed

CMakeLists.txt

Lines changed: 98 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,6 @@ option(FASTMCPP_BUILD_EXAMPLES "Build examples" ON)
1414
option(FASTMCPP_ENABLE_POST_STREAMING "Enable POST streaming via libcurl (optional)" OFF)
1515
option(FASTMCPP_FETCH_CURL "Fetch and build libcurl statically for POST streaming" ON)
1616
option(FASTMCPP_ENABLE_SAMPLING_HTTP_HANDLERS "Enable built-in OpenAI/Anthropic sampling handlers (requires libcurl)" OFF)
17-
option(FASTMCPP_ENABLE_WS_STREAMING_TESTS "Enable WebSocket streaming tests (requires external server)" OFF)
18-
option(FASTMCPP_ENABLE_LOCAL_WS_TEST "Enable local WebSocket server test (depends on httplib ws server support)" OFF)
1917

2018
add_library(fastmcpp_core STATIC
2119
src/types.cpp
@@ -24,7 +22,12 @@ add_library(fastmcpp_core STATIC
2422
src/providers/transforms/namespace.cpp
2523
src/providers/transforms/tool_transform.cpp
2624
src/providers/transforms/visibility.cpp
25+
src/providers/transforms/version_filter.cpp
26+
src/providers/transforms/prompts_as_tools.cpp
27+
src/providers/transforms/resources_as_tools.cpp
2728
src/providers/filesystem_provider.cpp
29+
src/providers/skills_provider.cpp
30+
src/providers/openapi_provider.cpp
2831
src/proxy.cpp
2932
src/mcp/handler.cpp
3033
src/mcp/tasks.cpp
@@ -40,6 +43,8 @@ add_library(fastmcpp_core STATIC
4043
src/server/context.cpp
4144
src/server/middleware.cpp
4245
src/server/security_middleware.cpp
46+
src/server/response_limiting_middleware.cpp
47+
src/server/ping_middleware.cpp
4348
src/server/sampling.cpp
4449
src/server/http_server.cpp
4550
src/server/stdio_server.cpp
@@ -92,19 +97,6 @@ if(NOT cpp_httplib_POPULATED)
9297
endif()
9398
target_include_directories(fastmcpp_core PUBLIC ${cpp_httplib_SOURCE_DIR})
9499

95-
# Header-only WebSocket client (easywsclient)
96-
FetchContent_Declare(
97-
easywsclient
98-
GIT_REPOSITORY https://github.com/dhbaird/easywsclient.git
99-
GIT_TAG master
100-
)
101-
FetchContent_GetProperties(easywsclient)
102-
if(NOT easywsclient_POPULATED)
103-
FetchContent_Populate(easywsclient)
104-
endif()
105-
target_include_directories(fastmcpp_core PUBLIC ${easywsclient_SOURCE_DIR})
106-
target_sources(fastmcpp_core PRIVATE ${easywsclient_SOURCE_DIR}/easywsclient.cpp)
107-
108100
# Optional: libcurl for POST streaming and sampling handlers (modular)
109101
if(FASTMCPP_ENABLE_POST_STREAMING OR FASTMCPP_ENABLE_SAMPLING_HTTP_HANDLERS)
110102
if(FASTMCPP_FETCH_CURL)
@@ -177,24 +169,8 @@ if(FASTMCPP_ENABLE_POST_STREAMING OR FASTMCPP_ENABLE_SAMPLING_HTTP_HANDLERS)
177169
endif()
178170
endif()
179171

180-
# TinyProcessLib for cross-platform subprocess (header-only)
181-
FetchContent_Declare(
182-
tiny_process_lib
183-
GIT_REPOSITORY https://github.com/eidheim/tiny-process-library.git
184-
GIT_TAG master
185-
)
186-
FetchContent_GetProperties(tiny_process_lib)
187-
if(NOT tiny_process_lib_POPULATED)
188-
FetchContent_Populate(tiny_process_lib)
189-
endif()
190-
target_include_directories(fastmcpp_core PUBLIC ${tiny_process_lib_SOURCE_DIR})
191-
target_compile_definitions(fastmcpp_core PUBLIC TINY_PROCESS_LIB_AVAILABLE)
192-
target_sources(fastmcpp_core PRIVATE ${tiny_process_lib_SOURCE_DIR}/process.cpp)
193-
if(UNIX)
194-
target_sources(fastmcpp_core PRIVATE ${tiny_process_lib_SOURCE_DIR}/process_unix.cpp)
195-
elseif(WIN32)
196-
target_sources(fastmcpp_core PRIVATE ${tiny_process_lib_SOURCE_DIR}/process_win.cpp)
197-
endif()
172+
# Cross-platform subprocess management (replaces tiny-process-library)
173+
target_sources(fastmcpp_core PRIVATE src/internal/process.cpp)
198174
find_package(Threads REQUIRED)
199175
target_link_libraries(fastmcpp_core PRIVATE Threads::Threads)
200176

@@ -248,6 +224,9 @@ if(FASTMCPP_BUILD_TESTS)
248224
add_test(NAME fastmcpp_cli_tasks_demo COMMAND fastmcpp tasks demo)
249225
add_executable(fastmcpp_cli_tasks_ux tests/cli/tasks_cli.cpp)
250226
add_test(NAME fastmcpp_cli_tasks_ux COMMAND fastmcpp_cli_tasks_ux)
227+
add_executable(fastmcpp_cli_generated_e2e tests/cli/generated_cli_e2e.cpp)
228+
target_link_libraries(fastmcpp_cli_generated_e2e PRIVATE fastmcpp_core)
229+
add_test(NAME fastmcpp_cli_generated_e2e COMMAND fastmcpp_cli_generated_e2e)
251230

252231
add_executable(fastmcpp_http_integration tests/server/http_integration.cpp)
253232
target_link_libraries(fastmcpp_http_integration PRIVATE fastmcpp_core)
@@ -273,6 +252,10 @@ if(FASTMCPP_BUILD_TESTS)
273252
target_link_libraries(fastmcpp_schema_build PRIVATE fastmcpp_core)
274253
add_test(NAME fastmcpp_schema_build COMMAND fastmcpp_schema_build)
275254

255+
add_executable(fastmcpp_schema_dereference_toggle tests/schema/dereference_toggle.cpp)
256+
target_link_libraries(fastmcpp_schema_dereference_toggle PRIVATE fastmcpp_core)
257+
add_test(NAME fastmcpp_schema_dereference_toggle COMMAND fastmcpp_schema_dereference_toggle)
258+
276259
add_executable(fastmcpp_content tests/content.cpp)
277260
target_link_libraries(fastmcpp_content PRIVATE fastmcpp_core)
278261
add_test(NAME fastmcpp_content COMMAND fastmcpp_content)
@@ -467,6 +450,26 @@ if(FASTMCPP_BUILD_TESTS)
467450
target_link_libraries(fastmcpp_stdio_failure PRIVATE fastmcpp_core)
468451
add_test(NAME fastmcpp_stdio_failure COMMAND fastmcpp_stdio_failure)
469452

453+
add_executable(fastmcpp_stdio_lifecycle tests/transports/stdio_lifecycle.cpp)
454+
target_link_libraries(fastmcpp_stdio_lifecycle PRIVATE fastmcpp_core)
455+
add_test(NAME fastmcpp_stdio_lifecycle COMMAND fastmcpp_stdio_lifecycle)
456+
set_tests_properties(fastmcpp_stdio_lifecycle PROPERTIES
457+
WORKING_DIRECTORY "$<TARGET_FILE_DIR:fastmcpp_stdio_lifecycle>"
458+
)
459+
460+
add_executable(fastmcpp_stdio_stderr tests/transports/stdio_stderr.cpp)
461+
target_link_libraries(fastmcpp_stdio_stderr PRIVATE fastmcpp_core)
462+
add_test(NAME fastmcpp_stdio_stderr COMMAND fastmcpp_stdio_stderr)
463+
set_tests_properties(fastmcpp_stdio_stderr PROPERTIES
464+
WORKING_DIRECTORY "$<TARGET_FILE_DIR:fastmcpp_stdio_stderr>"
465+
)
466+
467+
add_executable(fastmcpp_stdio_timeout tests/transports/stdio_timeout.cpp)
468+
target_link_libraries(fastmcpp_stdio_timeout PRIVATE fastmcpp_core)
469+
add_test(NAME fastmcpp_stdio_timeout COMMAND fastmcpp_stdio_timeout)
470+
# Timeout test can take up to ~35 seconds
471+
set_tests_properties(fastmcpp_stdio_timeout PROPERTIES TIMEOUT 60)
472+
470473
# App mounting tests
471474
add_executable(fastmcpp_app_mounting tests/app/mounting.cpp)
472475
target_link_libraries(fastmcpp_app_mounting PRIVATE fastmcpp_core)
@@ -477,6 +480,11 @@ if(FASTMCPP_BUILD_TESTS)
477480
target_link_libraries(fastmcpp_app_ergonomics PRIVATE fastmcpp_core)
478481
add_test(NAME fastmcpp_app_ergonomics COMMAND fastmcpp_app_ergonomics)
479482

483+
# MCP Apps metadata parity tests
484+
add_executable(fastmcpp_app_mcp_apps tests/app/mcp_apps.cpp)
485+
target_link_libraries(fastmcpp_app_mcp_apps PRIVATE fastmcpp_core)
486+
add_test(NAME fastmcpp_app_mcp_apps COMMAND fastmcpp_app_mcp_apps)
487+
480488
# Filesystem provider tests
481489
add_library(fastmcpp_fs_test_plugin SHARED tests/fs/test_plugin.cpp)
482490
target_compile_definitions(fastmcpp_fs_test_plugin PRIVATE FASTMCPP_PROVIDER_EXPORTS)
@@ -497,6 +505,22 @@ if(FASTMCPP_BUILD_TESTS)
497505
target_link_libraries(fastmcpp_provider_transforms PRIVATE fastmcpp_core)
498506
add_test(NAME fastmcpp_provider_transforms COMMAND fastmcpp_provider_transforms)
499507

508+
add_executable(fastmcpp_provider_version_filter tests/providers/version_filter.cpp)
509+
target_link_libraries(fastmcpp_provider_version_filter PRIVATE fastmcpp_core)
510+
add_test(NAME fastmcpp_provider_version_filter COMMAND fastmcpp_provider_version_filter)
511+
512+
add_executable(fastmcpp_provider_skills tests/providers/skills_provider.cpp)
513+
target_link_libraries(fastmcpp_provider_skills PRIVATE fastmcpp_core)
514+
add_test(NAME fastmcpp_provider_skills COMMAND fastmcpp_provider_skills)
515+
516+
add_executable(fastmcpp_provider_skills_paths tests/providers/skills_path_resolution.cpp)
517+
target_link_libraries(fastmcpp_provider_skills_paths PRIVATE fastmcpp_core)
518+
add_test(NAME fastmcpp_provider_skills_paths COMMAND fastmcpp_provider_skills_paths)
519+
520+
add_executable(fastmcpp_provider_openapi tests/providers/openapi_provider.cpp)
521+
target_link_libraries(fastmcpp_provider_openapi PRIVATE fastmcpp_core)
522+
add_test(NAME fastmcpp_provider_openapi COMMAND fastmcpp_provider_openapi)
523+
500524
# Proxy tests
501525
add_executable(fastmcpp_proxy_basic tests/proxy/basic.cpp)
502526
target_link_libraries(fastmcpp_proxy_basic PRIVATE fastmcpp_core)
@@ -507,6 +531,31 @@ if(FASTMCPP_BUILD_TESTS)
507531
target_link_libraries(fastmcpp_main_header PRIVATE fastmcpp_core)
508532
add_test(NAME fastmcpp_main_header COMMAND fastmcpp_main_header)
509533

534+
# Sync-cycle tests (Phase 11)
535+
add_executable(fastmcpp_mcp_error_codes tests/mcp/test_error_codes.cpp)
536+
target_link_libraries(fastmcpp_mcp_error_codes PRIVATE fastmcpp_core)
537+
add_test(NAME fastmcpp_mcp_error_codes COMMAND fastmcpp_mcp_error_codes)
538+
539+
add_executable(fastmcpp_pagination tests/mcp/test_pagination.cpp)
540+
target_link_libraries(fastmcpp_pagination PRIVATE fastmcpp_core)
541+
add_test(NAME fastmcpp_pagination COMMAND fastmcpp_pagination)
542+
543+
add_executable(fastmcpp_tools_transform_enabled tests/tools/test_tool_transform_enabled.cpp)
544+
target_link_libraries(fastmcpp_tools_transform_enabled PRIVATE fastmcpp_core)
545+
add_test(NAME fastmcpp_tools_transform_enabled COMMAND fastmcpp_tools_transform_enabled)
546+
547+
add_executable(fastmcpp_tools_sequential tests/tools/test_tool_sequential.cpp)
548+
target_link_libraries(fastmcpp_tools_sequential PRIVATE fastmcpp_core)
549+
add_test(NAME fastmcpp_tools_sequential COMMAND fastmcpp_tools_sequential)
550+
551+
add_executable(fastmcpp_session_state tests/server/test_session_state.cpp)
552+
target_link_libraries(fastmcpp_session_state PRIVATE fastmcpp_core)
553+
add_test(NAME fastmcpp_session_state COMMAND fastmcpp_session_state)
554+
555+
add_executable(fastmcpp_response_limiting tests/server/test_response_limiting.cpp)
556+
target_link_libraries(fastmcpp_response_limiting PRIVATE fastmcpp_core)
557+
add_test(NAME fastmcpp_response_limiting COMMAND fastmcpp_response_limiting)
558+
510559
set_tests_properties(fastmcpp_stdio_client PROPERTIES
511560
LABELS "conformance"
512561
WORKING_DIRECTORY "$<TARGET_FILE_DIR:fastmcpp_stdio_client>"
@@ -527,20 +576,6 @@ if(FASTMCPP_BUILD_TESTS)
527576
set_tests_properties(fastmcpp_streaming_sse PROPERTIES RUN_SERIAL TRUE)
528577
endif()
529578

530-
if(FASTMCPP_ENABLE_WS_STREAMING_TESTS)
531-
add_executable(fastmcpp_ws_streaming tests/transports/ws_streaming.cpp)
532-
target_link_libraries(fastmcpp_ws_streaming PRIVATE fastmcpp_core)
533-
add_test(NAME fastmcpp_ws_streaming COMMAND fastmcpp_ws_streaming)
534-
# Test auto-skips if FASTMCPP_WS_URL is not set
535-
536-
if(FASTMCPP_ENABLE_LOCAL_WS_TEST)
537-
add_executable(fastmcpp_ws_streaming_local tests/transports/ws_streaming_local.cpp)
538-
target_link_libraries(fastmcpp_ws_streaming_local PRIVATE fastmcpp_core)
539-
add_test(NAME fastmcpp_ws_streaming_local COMMAND fastmcpp_ws_streaming_local)
540-
set_tests_properties(fastmcpp_ws_streaming_local PROPERTIES RUN_SERIAL TRUE)
541-
endif()
542-
endif()
543-
544579
# POST streaming transport test (requires libcurl)
545580
if(FASTMCPP_ENABLE_POST_STREAMING AND TARGET CURL::libcurl)
546581
add_executable(fastmcpp_post_streaming tests/transports/post_streaming.cpp)
@@ -585,6 +620,18 @@ if(FASTMCPP_BUILD_EXAMPLES)
585620
add_executable(fastmcpp_example_tags_example examples/tags_example.cpp)
586621
target_link_libraries(fastmcpp_example_tags_example PRIVATE fastmcpp_core)
587622

623+
# MCP Apps example (FastMCP 3.x surface)
624+
add_executable(fastmcpp_example_mcp_apps examples/mcp_apps.cpp)
625+
target_link_libraries(fastmcpp_example_mcp_apps PRIVATE fastmcpp_core)
626+
627+
# Skills provider example
628+
add_executable(fastmcpp_example_skills_provider examples/skills_provider.cpp)
629+
target_link_libraries(fastmcpp_example_skills_provider PRIVATE fastmcpp_core)
630+
631+
# OpenAPI provider example
632+
add_executable(fastmcpp_example_openapi_provider examples/openapi_provider.cpp)
633+
target_link_libraries(fastmcpp_example_openapi_provider PRIVATE fastmcpp_core)
634+
588635
# Context API example (v2.13.0+)
589636
add_executable(fastmcpp_example_context_introspection examples/context_introspection.cpp)
590637
target_link_libraries(fastmcpp_example_context_introspection PRIVATE fastmcpp_core)
@@ -605,6 +652,10 @@ if(FASTMCPP_BUILD_EXAMPLES)
605652
add_executable(fastmcpp_example_tool_injection_middleware examples/tool_injection_middleware.cpp)
606653
target_link_libraries(fastmcpp_example_tool_injection_middleware PRIVATE fastmcpp_core)
607654

655+
# Response Limiting Middleware example
656+
add_executable(fastmcpp_example_response_limiting_middleware examples/response_limiting_middleware.cpp)
657+
target_link_libraries(fastmcpp_example_response_limiting_middleware PRIVATE fastmcpp_core)
658+
608659
# Server Metadata example (v2.13.0+)
609660
add_executable(fastmcpp_example_server_metadata examples/server_metadata.cpp)
610661
target_link_libraries(fastmcpp_example_server_metadata PRIVATE fastmcpp_core)

README.md

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111

1212
---
1313

14-
fastmcpp is a C++ port of the Python [fastmcp](https://github.com/jlowin/fastmcp) library, providing native performance for MCP servers and clients with support for tools, resources, prompts, and multiple transport layers (STDIO, HTTP/SSE, WebSocket).
14+
fastmcpp is a C++ port of the Python [fastmcp](https://github.com/jlowin/fastmcp) library, providing native performance for MCP servers and clients with support for tools, resources, prompts, and MCP-standard transport layers (STDIO, HTTP/SSE, Streamable HTTP).
1515

1616
**Status:** Beta – core MCP features track the Python `fastmcp` reference.
1717

@@ -20,7 +20,7 @@ fastmcpp is a C++ port of the Python [fastmcp](https://github.com/jlowin/fastmcp
2020
## Features
2121

2222
- Core MCP protocol implementation (JSON‑RPC).
23-
- Multiple transports: STDIO, HTTP (SSE), Streamable HTTP, WebSocket.
23+
- Multiple transports: STDIO, HTTP (SSE), Streamable HTTP.
2424
- Streamable HTTP transport (MCP spec 2025-03-26) with session management.
2525
- Tool management and invocation.
2626
- Resources and prompts support.
@@ -47,7 +47,6 @@ Optional:
4747

4848
- libcurl (for HTTP POST streaming; can be fetched when `FASTMCPP_FETCH_CURL=ON`).
4949
- cpp‑httplib (HTTP server, fetched automatically).
50-
- easywsclient (WebSocket client, fetched automatically).
5150

5251
## Building
5352

@@ -68,8 +67,7 @@ cmake -B build -S . \
6867
-DCMAKE_BUILD_TYPE=Release \
6968
-DFASTMCPP_ENABLE_POST_STREAMING=ON \
7069
-DFASTMCPP_FETCH_CURL=ON \
71-
-DFASTMCPP_ENABLE_STREAMING_TESTS=ON \
72-
-DFASTMCPP_ENABLE_WS_STREAMING_TESTS=ON
70+
-DFASTMCPP_ENABLE_STREAMING_TESTS=ON
7371
```
7472

7573
Key options:
@@ -80,7 +78,6 @@ Key options:
8078
| `FASTMCPP_ENABLE_POST_STREAMING` | OFF | Enable HTTP POST streaming (requires libcurl) |
8179
| `FASTMCPP_FETCH_CURL` | OFF | Fetch and build curl (via FetchContent) if not found |
8280
| `FASTMCPP_ENABLE_STREAMING_TESTS` | OFF | Enable SSE streaming tests |
83-
| `FASTMCPP_ENABLE_WS_STREAMING_TESTS` | OFF | Enable WebSocket streaming tests |
8481

8582
### Platform notes
8683

@@ -276,7 +273,6 @@ int main() {
276273
277274
The `create_proxy()` factory function automatically detects the transport type from the URL:
278275
- `http://` or `https://` URLs use HTTP transport
279-
- `ws://` or `wss://` URLs use WebSocket transport
280276
281277
Local tools, resources, and prompts take precedence over remote ones with the same name.
282278

examples/mcp_apps.cpp

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
#include "fastmcpp/app.hpp"
2+
#include "fastmcpp/mcp/handler.hpp"
3+
#include "fastmcpp/server/stdio_server.hpp"
4+
5+
#include <string>
6+
7+
int main()
8+
{
9+
using fastmcpp::AppConfig;
10+
using fastmcpp::FastMCP;
11+
using fastmcpp::Json;
12+
13+
FastMCP app("mcp_apps_example", "1.0.0");
14+
15+
// Tool with MCP Apps metadata under _meta.ui (resourceUri + visibility)
16+
FastMCP::ToolOptions tool_opts;
17+
AppConfig tool_ui;
18+
tool_ui.resource_uri = "ui://widgets/echo.html";
19+
tool_ui.visibility = std::vector<std::string>{"tool_result"};
20+
tool_opts.app = tool_ui;
21+
22+
app.tool("echo_ui", [](const Json& in) { return in; }, tool_opts);
23+
24+
// UI resource: mime_type defaults to text/html;profile=mcp-app for ui:// URIs
25+
FastMCP::ResourceOptions resource_opts;
26+
AppConfig resource_ui;
27+
resource_ui.domain = "https://example.local";
28+
resource_ui.prefers_border = true;
29+
resource_opts.app = resource_ui;
30+
31+
app.resource(
32+
"ui://widgets/home.html", "Home Widget",
33+
[](const Json&)
34+
{
35+
return fastmcpp::resources::ResourceContent{
36+
"ui://widgets/home.html", std::nullopt,
37+
std::string{"<html><body><h1>Home</h1></body></html>"}};
38+
},
39+
resource_opts);
40+
41+
// UI resource template with per-template metadata
42+
FastMCP::ResourceTemplateOptions templ_opts;
43+
AppConfig templ_ui;
44+
templ_ui.csp = Json{{"connectDomains", Json::array({"https://api.example.test"})}};
45+
templ_opts.app = templ_ui;
46+
47+
app.resource_template(
48+
"ui://widgets/{name}.html", "Named Widget",
49+
[](const Json& params)
50+
{
51+
const std::string name = params.value("name", "unknown");
52+
return fastmcpp::resources::ResourceContent{
53+
"ui://widgets/" + name + ".html", std::nullopt,
54+
std::string{"<html><body><h1>" + name + "</h1></body></html>"}};
55+
},
56+
Json::object(), templ_opts);
57+
58+
auto handler = fastmcpp::mcp::make_mcp_handler(app);
59+
fastmcpp::server::StdioServerWrapper server(handler);
60+
server.run();
61+
return 0;
62+
}

examples/openapi_provider.cpp

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
#include "fastmcpp/providers/openapi_provider.hpp"
2+
3+
#include "fastmcpp/app.hpp"
4+
5+
#include <iostream>
6+
#include <memory>
7+
8+
int main()
9+
{
10+
using namespace fastmcpp;
11+
12+
Json spec = Json::object();
13+
spec["openapi"] = "3.0.3";
14+
spec["info"] = Json{{"title", "Example API"}, {"version", "1.0.0"}};
15+
spec["servers"] = Json::array({Json{{"url", "http://127.0.0.1:8080"}}});
16+
spec["paths"] = Json::object();
17+
spec["paths"]["/status"]["get"] = Json{
18+
{"operationId", "getStatus"},
19+
{"responses",
20+
Json{{"200", Json{{"description", "ok"},
21+
{"content",
22+
Json{{"application/json",
23+
Json{{"schema",
24+
Json{{"type", "object"},
25+
{"properties",
26+
Json{{"status", Json{{"type", "string"}}}}}}}}}}}}}}},
27+
};
28+
29+
FastMCP app("openapi-provider-example", "1.0.0");
30+
auto provider = std::make_shared<providers::OpenAPIProvider>(spec);
31+
app.add_provider(provider);
32+
33+
std::cout << "OpenAPI tools discovered:\n";
34+
for (const auto& tool : app.list_all_tools_info())
35+
std::cout << " - " << tool.name << "\n";
36+
std::cout << "Run a compatible HTTP server at http://127.0.0.1:8080 to invoke these tools.\n";
37+
return 0;
38+
}

0 commit comments

Comments
 (0)