runninghub-api
    runninghub-api
    • Instructions for Use
    • About nodeInfoList
    • About Enterprise ComfyUI API
    • Native ComfyUI API Integration Guide
    • Start ComfyUI Task 1 - Basic
      POST
    • Start ComfyUI Task 2 - Advanced
      POST
    • Start AI App Task
      POST
    • Get Workflow JSON
      POST
    • Check Task Status
      POST
    • Check Task Output
      POST
    • Cancel ComfyUI Task
      POST
    • Get Account Information
      POST
    • Upload Resource(image\video\audio)
      POST
    • Upload Lora
      POST
    • Get Webhook Event Details
      POST
    • Resend Specific Webhook Event
      POST

    About nodeInfoList

    What is nodeId, fieldName?

    In the workflow interface, each node has a number at the top-right corner — that is the nodeId.

    image

    Before calling the API to start a ComfyUI task, familiarize yourself with the api_format file of the workflow.

    1. Click the download icon at the top of the RunningHub interface.
    2. Select Export Workflow API.
    3. After downloading, open the file — it is a standard JSON file.
    image image

    Each nodeId corresponds to an inputs section. The keys within inputs are the fieldNames.
    When you modify a node’s value in the workflow, you are essentially changing the fieldValue for a given fieldName.

    For example, to change the text in a text-to-image example and the random seed in KSampler, you would look for nodes with nodeId "6" and "3" in the workflow file, then search for those numbers in the JSON.

    image image
    • The fieldName for the text is "text".
    • The fieldName for the random seed is "seed".

    Construct the nodeInfoList as follows:

    "nodeInfoList": [
      {
        "nodeId": "6",
        "fieldName": "text",
        "fieldValue": "1 girl in classroom"
      },
      {
        "nodeId": "3",
        "fieldName": "seed",
        "fieldValue": "1231231"
      }
    ]
    

    Regarding uploading images for image-to-image workflows

    There are two approaches to providing an image for the workflow:

    1. Maintain your own image hosting service and use the LoadImageFromUrl node.
      When the workflow reaches this node, it will download the image from the specified URL.

      image image

      Construct the nodeInfoList as follows:

      "nodeInfoList": [
        {
          "nodeId": "13",
          "fieldName": "image",
          "fieldValue": "https://rh-images.xiaoyaoyou.com/de0db6f2564c8697b07df55a77f07be9/output/ComfyUI_00038_sffft_1742964027.png?imageMogr2/format/jpeg/ignore-error/1"
        }
      ]
      
    2. Use the Upload Resource API.
      After calling the resource upload API, pass the returned fileName into the LoadImage node.
      For example:

      {
        "code": 0,
        "msg": "success",
        "data": {
          "fileName": "api/9d77b8530f8b3591edc5c4e8f3f55b2cf0960bb2ca35c04e32c1677687866576.png",
          "fileType": "image"
        }
      }
      
      "nodeInfoList": [
        {
          "nodeId": "14",
          "fieldName": "image",
          "fieldValue": "api/9d77b8530f8b3591edc5c4e8f3f55b2cf0960bb2ca35c04e32c1677687866576.png"
        }
      ]
      

    Regarding uploading Lora

    Currently, there is only one solution, consisting of three steps:

    1. Call the API to get the Lora upload URL.
    2. Use the returned URL to upload the Lora file.
    3. Use the uploaded Lora in the RHLoraLoader node.
    image

    Notes

    1. API calls do not automatically change the seed value.

      • The same workflow with the same inputs will always produce the same image.
      • You must manually generate a random seed and include it in nodeInfoList.
    2. If a fieldName cannot be found in the API-format workflow, that means it’s a purely front-end field that only works in the browser — for example, control_after_generate in KSampler. Similarly, group-related logic is not supported via API.

    3. In API-format workflows, a fieldValue wrapped in [] typically indicates a connection (wiring) between nodes.

      • It is not recommended to modify these values.
    Modified at 2025-04-15 07:34:08
    Previous
    Instructions for Use
    Next
    About Enterprise ComfyUI API
    Built with