tianruci commited on
Commit
49846c3
·
verified ·
1 Parent(s): fb086fc

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +12 -1
app.py CHANGED
@@ -96,4 +96,15 @@ async def root():
96
  async def get_trending(num: int = 10):
97
  if not cached_trending:
98
  await fetch_github_trending()
99
- return {"trending": cached_trending[:num]}
 
 
 
 
 
 
 
 
 
 
 
 
96
  async def get_trending(num: int = 10):
97
  if not cached_trending:
98
  await fetch_github_trending()
99
+ return {"trending": cached_trending[:num]}
100
+
101
+ # 在app.py中添加
102
+ @app.get("/mcp/")
103
+ async def mcp_root():
104
+ return {
105
+ "message": "MCP API root",
106
+ "endpoints": {
107
+ "tools": "/mcp/tool",
108
+ "schema": "/mcp/schema"
109
+ }
110
+ }