88namespace fastmcpp
99{
1010
11- McpApp::McpApp (std::string name, std::string version, std::optional<std::string> website_url,
12- std::optional<std::vector<Icon>> icons)
11+ FastMCP::FastMCP (std::string name, std::string version, std::optional<std::string> website_url,
12+ std::optional<std::vector<Icon>> icons)
1313 : server_(std::move(name), std::move(version), std::move(website_url), std::move(icons))
1414{
1515}
1616
17- void McpApp ::mount (McpApp & app, const std::string& prefix, bool as_proxy)
17+ void FastMCP ::mount (FastMCP & app, const std::string& prefix, bool as_proxy)
1818{
1919 if (as_proxy)
2020 {
@@ -40,22 +40,22 @@ void McpApp::mount(McpApp& app, const std::string& prefix, bool as_proxy)
4040// Prefix Utilities
4141// =========================================================================
4242
43- std::string McpApp ::add_prefix (const std::string& name, const std::string& prefix)
43+ std::string FastMCP ::add_prefix (const std::string& name, const std::string& prefix)
4444{
4545 if (prefix.empty ())
4646 return name;
4747 return prefix + " _" + name;
4848}
4949
50- std::pair<std::string, std::string> McpApp ::strip_prefix (const std::string& name)
50+ std::pair<std::string, std::string> FastMCP ::strip_prefix (const std::string& name)
5151{
5252 auto pos = name.find (' _' );
5353 if (pos == std::string::npos)
5454 return {" " , name};
5555 return {name.substr (0 , pos), name.substr (pos + 1 )};
5656}
5757
58- std::string McpApp ::add_resource_prefix (const std::string& uri, const std::string& prefix)
58+ std::string FastMCP ::add_resource_prefix (const std::string& uri, const std::string& prefix)
5959{
6060 if (prefix.empty ())
6161 return uri;
@@ -73,7 +73,7 @@ std::string McpApp::add_resource_prefix(const std::string& uri, const std::strin
7373 return scheme + " ://" + prefix + " /" + path;
7474}
7575
76- std::string McpApp ::strip_resource_prefix (const std::string& uri, const std::string& prefix)
76+ std::string FastMCP ::strip_resource_prefix (const std::string& uri, const std::string& prefix)
7777{
7878 if (prefix.empty ())
7979 return uri;
@@ -93,7 +93,7 @@ std::string McpApp::strip_resource_prefix(const std::string& uri, const std::str
9393 return uri;
9494}
9595
96- bool McpApp ::has_resource_prefix (const std::string& uri, const std::string& prefix)
96+ bool FastMCP ::has_resource_prefix (const std::string& uri, const std::string& prefix)
9797{
9898 if (prefix.empty ())
9999 return true ; // Empty prefix matches everything
@@ -112,7 +112,7 @@ bool McpApp::has_resource_prefix(const std::string& uri, const std::string& pref
112112// Aggregated Lists
113113// =========================================================================
114114
115- std::vector<std::pair<std::string, const tools::Tool*>> McpApp ::list_all_tools () const
115+ std::vector<std::pair<std::string, const tools::Tool*>> FastMCP ::list_all_tools () const
116116{
117117 std::vector<std::pair<std::string, const tools::Tool*>> result;
118118
@@ -153,7 +153,7 @@ std::vector<std::pair<std::string, const tools::Tool*>> McpApp::list_all_tools()
153153 return result;
154154}
155155
156- std::vector<client::ToolInfo> McpApp ::list_all_tools_info () const
156+ std::vector<client::ToolInfo> FastMCP ::list_all_tools_info () const
157157{
158158 std::vector<client::ToolInfo> result;
159159
@@ -200,7 +200,7 @@ std::vector<client::ToolInfo> McpApp::list_all_tools_info() const
200200 return result;
201201}
202202
203- std::vector<resources::Resource> McpApp ::list_all_resources () const
203+ std::vector<resources::Resource> FastMCP ::list_all_resources () const
204204{
205205 std::vector<resources::Resource> result;
206206
@@ -247,7 +247,7 @@ std::vector<resources::Resource> McpApp::list_all_resources() const
247247 return result;
248248}
249249
250- std::vector<resources::ResourceTemplate> McpApp ::list_all_templates () const
250+ std::vector<resources::ResourceTemplate> FastMCP ::list_all_templates () const
251251{
252252 std::vector<resources::ResourceTemplate> result;
253253
@@ -293,7 +293,7 @@ std::vector<resources::ResourceTemplate> McpApp::list_all_templates() const
293293 return result;
294294}
295295
296- std::vector<std::pair<std::string, const prompts::Prompt*>> McpApp ::list_all_prompts () const
296+ std::vector<std::pair<std::string, const prompts::Prompt*>> FastMCP ::list_all_prompts () const
297297{
298298 std::vector<std::pair<std::string, const prompts::Prompt*>> result;
299299
@@ -335,7 +335,7 @@ std::vector<std::pair<std::string, const prompts::Prompt*>> McpApp::list_all_pro
335335// Routing
336336// =========================================================================
337337
338- Json McpApp ::invoke_tool (const std::string& name, const Json& args) const
338+ Json FastMCP ::invoke_tool (const std::string& name, const Json& args) const
339339{
340340 // Try local tools first
341341 try
@@ -437,7 +437,7 @@ Json McpApp::invoke_tool(const std::string& name, const Json& args) const
437437 throw NotFoundError (" tool not found: " + name);
438438}
439439
440- resources::ResourceContent McpApp ::read_resource (const std::string& uri, const Json& params) const
440+ resources::ResourceContent FastMCP ::read_resource (const std::string& uri, const Json& params) const
441441{
442442 // Try local resources first
443443 try
@@ -562,8 +562,8 @@ resources::ResourceContent McpApp::read_resource(const std::string& uri, const J
562562 throw NotFoundError (" resource not found: " + uri);
563563}
564564
565- std::vector<prompts::PromptMessage> McpApp ::get_prompt (const std::string& name,
566- const Json& args) const
565+ std::vector<prompts::PromptMessage> FastMCP ::get_prompt (const std::string& name,
566+ const Json& args) const
567567{
568568 // Try local prompts first
569569 try
0 commit comments