(
tool_id: str,
payload: ToolPermissionRequest,
_auth: AuthContext = Depends(require_tool_scope),
service: ToolsService = Depends(get_service),
)
| 197 | |
| 198 | @router.patch("/tools/{tool_id:path}/permission") |
| 199 | async def set_tool_permission( |
| 200 | tool_id: str, |
| 201 | payload: ToolPermissionRequest, |
| 202 | _auth: AuthContext = Depends(require_tool_scope), |
| 203 | service: ToolsService = Depends(get_service), |
| 204 | ): |
| 205 | return await _run( |
| 206 | lambda: service.update_tool_permission( |
| 207 | {"name": tool_id, "permission": payload.permission} |
| 208 | ), |
| 209 | result_as_message=True, |
| 210 | ) |
| 211 | |
| 212 | |
| 213 | @router.get("/mcp/servers") |
nothing calls this directly
no test coverage detected