mcp transport
This commit is contained in:
+9
-1
@@ -568,4 +568,12 @@ def odoo_get_record(model: str, record_id: int) -> dict:
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
mcp.run()
|
||||
transport = os.environ.get("MCP_TRANSPORT", "stdio")
|
||||
if transport == "http":
|
||||
mcp.run(
|
||||
transport="streamable-http",
|
||||
host=os.environ.get("MCP_HOST", "0.0.0.0"),
|
||||
port=int(os.environ.get("MCP_PORT", "8080")),
|
||||
)
|
||||
else:
|
||||
mcp.run()
|
||||
|
||||
Reference in New Issue
Block a user