File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed
Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change 66
77if TYPE_CHECKING :
88 from fastapi import APIRouter , FastAPI , Request , Response
9+ from fastapi .responses import JSONResponse
910
1011 _package_fastapi_installed = True
1112else :
1213 try :
1314 from fastapi import APIRouter , FastAPI , Request , Response
15+ from fastapi .responses import JSONResponse
1416
1517 _package_fastapi_installed = True
1618 except ImportError :
@@ -111,7 +113,8 @@ def build(
111113
112114 @router .get (f'{ rpc_url } { agent_card_url } ' )
113115 async def get_agent_card (request : Request ) -> Response :
114- return await self ._adapter .handle_get_agent_card (request )
116+ card = await self ._adapter .handle_get_agent_card (request )
117+ return JSONResponse (card )
115118
116119 app .include_router (router )
117120 return app
You can’t perform that action at this time.
0 commit comments