https://github.com/9elements/comfyui-api
https://github.com/9elements/comfyui-api
Last synced: 3 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/9elements/comfyui-api
- Owner: 9elements
- Created: 2024-01-26T15:04:45.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-02-07T07:24:50.000Z (over 1 year ago)
- Last Synced: 2025-04-12T00:37:19.690Z (3 months ago)
- Language: Python
- Size: 607 KB
- Stars: 120
- Watchers: 2
- Forks: 29
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# comfyui-api
Install missing packages via `requirements.txt`
`pip install -r requirements.txt`
## Using the API
You need to a comfyUI server running and be able to access the "/ws" path for this server. If you have the server running localy it usually runs under "127.0.0.1:8188".
If this is not the case for you, change the `server_address` in the `basic_api.py`.In the workflow folder are two basic Workflows:
- base_workflow.json
- baisc_image_to_imageFor simple prompt to image generation load the `base_workflow.json` and call `prompt_to_image` method with your desired parameters.
For image to image generation load the `basic_image_to_image.json` and put your input image in the input folder. Call `prompt_image_to_image` with your desired parameters.