Files
2frames-ComfyUI-AQnodes/__init__.py
T
google-labs-jules[bot] 9f61280ea7 refactor: Add 'result' output to AQ_SendImageToAPI node
Based on your feedback, this commit further modifies the `AQ_SendImageToAPI` node in `nodes/api/AQ_SendImageToAPI.py`:

- **Added `result` output string:**
    - `RETURN_TYPES` updated to `("STRING", "STRING",)`.
    - `RETURN_NAMES` updated to `("instruction", "result",)`.
- The `send_images_to_api` method now captures the outcome of the API call (or image processing).
    - If successful, the `result` string will contain the HTTP status and response from the server.
    - If an error occurs (e.g., network issue, server error), the `result` string will contain the error message.
    - If no images are provided, a message indicating this is returned in the `result` string.
- This `result` output provides a way to access the final status of the API interaction within the ComfyUI workflow, complementing the real-time UI updates from `update_node_status`.
2025-05-21 18:05:53 +00:00

28 lines
1008 B
Python

from .nodes.pulid.AQ_MasksAndImagesAsList import AQ_MasksAndImagesAsList
from .nodes.transformers.AQ_Qwen import AQ_Qwen
from .nodes.transformers.AQ_Qwen import AQ_QwenLoader
from .nodes.pulid.AQ_multiface_ApplyPulidFlux import AQ_multiface_ApplyPulidFlux
from .nodes.api.AQ_Gemini import AQ_Gemini
from .nodes.api.AQ_SendImageToAPI import AQ_SendImageToAPI
NODE_CLASS_MAPPINGS = {
"AQ_MasksAndImagesAsList": AQ_MasksAndImagesAsList,
"AQ_multiface_ApplyPulidFlux": AQ_multiface_ApplyPulidFlux,
"AQ_Qwen": AQ_Qwen,
"AQ_QwenLoader": AQ_QwenLoader,
"AQ_Gemini": AQ_Gemini,
"AQ_SendImageToAPI": AQ_SendImageToAPI
}
NODE_DISPLAY_NAME_MAPPINGS = {
"AQ_MasksAndImagesAsList": "AQ_MasksAndImagesAsList",
"AQ_multiface_ApplyPulidFlux": "AQ_multiface_ApplyPulidFlux",
"AQ_Qwen": "AQ_Qwen",
"AQ_QwenLoader": "AQ_QwenLoader",
"AQ_Gemini": "AQ_Gemini",
"AQ_SendImageToAPI": "Aquasite Send Image to API"
}
__all__ = ['NODE_CLASS_MAPPINGS', 'NODE_DISPLAY_NAME_MAPPINGS']