feat(server): expose comfy_api_base in system_stats response

Add system.comfy_api_base to /api/system_stats so clients (especially
the static preview frontend) can read the configured cloud API base
URL directly instead of parsing it out of argv.

The value is always present: it defaults to https://api.comfy.org
when --comfy-api-base is not specified, matching the existing default
in cli_args.py.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
snomiao 2026-04-27 07:27:23 +09:00
parent 7385eb2800
commit fb651763bf

View File

@ -668,7 +668,8 @@ class PromptServer():
"python_version": sys.version, "python_version": sys.version,
"pytorch_version": comfy.model_management.torch_version, "pytorch_version": comfy.model_management.torch_version,
"embedded_python": os.path.split(os.path.split(sys.executable)[0])[1] == "python_embeded", "embedded_python": os.path.split(os.path.split(sys.executable)[0])[1] == "python_embeded",
"argv": sys.argv "argv": sys.argv,
"comfy_api_base": args.comfy_api_base
}, },
"devices": [ "devices": [
{ {