## Basic tool info Model name: alibaba/wan 2.7 image Model description: Alibaba Wan 2.7 Image generates or edits PNG images from text and up to 9 reference images. It supports 1K or 2K output and coherent image sets up to 12 images. Model cover: https://cdn.wiro.ai/uploads/models/alibaba-wan-2-7-image-cover.webp Model categories: - tool - partner - nogpu-pipeline - alibaba - quick-showcase - text-to-image - image-to-image Run Task Endpoint (POST): https://api.wiro.ai/v1/Run/alibaba/wan-2-7-image Get Task Detail Endpoint (POST): https://api.wiro.ai/v1/Task/Detail ## Model Inputs: - name: inputImage label: Input Images help: Optional. Up to 9 images to edit or use as reference. Leave empty to generate from the prompt alone. Refer to them in the prompt as image 1, image 2 and so on type: combinefileinput default: alibaba-wan-2-7-image-sampleinput-5.jpeg - name: prompt label: prompt help: Required. The prompt to generate the image. Max 5000 characters. type: textarea default: A cinematic image set following the woman in image 1 through one day in a small California coastal town. Keep her face, hair and clothing consistent in every image. Image 1: early morning, she stands on a wooden pier holding a paper coffee cup, looking out at the flat grey sea, soft blue light and mist. Image 2: midday, she walks along a sunlit street of pastel storefronts, hands in her pockets, palm shadows across the pavement. Image 3: late afternoon, she sits on warm sand with her knees up, sunglasses pushed into her hair, watching the waves, warm golden light. Image 4: sunset, she leans on a railing above the beach with the orange sky behind her and the wind lifting her hair. Photorealistic, natural film colors, 35mm. - name: size label: Resolution help: Required. Quality tier for the generated image. The aspect ratio follows the first input image, or is square when there is no input image. type: select default: 1K options: - value: "1K" label: 1K - value: "2K" label: 2K - name: samples label: Number of Images help: Optional. If Sequential is false, up to 4 images are generated. If Sequential is true, up to 12 images are generated and the model decides the final count without exceeding this value. Each generated image is billed. type: number default: 1 - name: enableSequential label: Sequential help: Optional. Generates one coherent series that keeps the same subject and style across the images instead of separate takes on the prompt. Describe each image in the prompt as image 1, image 2 and so on. type: select default: false options: - value: "false" label: false - value: "true" label: true - name: thinkingMode label: Thinking Mode help: Optional. Improves output quality at the cost of longer generation time. Only applies when there is no input image and Sequential is false. The price is the same either way. type: select default: true options: - value: "true" label: true - value: "false" label: false - name: seed label: Seed help: Optional. Random seed for reproducibility (0-2147483647). type: number default: ## Model Parameter Inspires: - prompt: Change the weather to a heavy summer thunderstorm. Rain streaks through the air, the road is soaked and reflective, water runs along the edge of the asphalt, dark clouds cover the ridges and the light turns cold and grey. Keep the cyclist and the bike exactly the same. - inputImage: https://cdn.wiro.ai/uploads/sampleinputs/alibaba-wan-2-7-image-sampleinput-1.jpeg - samples: 1 - enableSequential: false - prompt: Turn the mug bright terracotta orange with a glossy glaze, add steam rising from it, and replace the background with a blurred cafe interior at golden hour. - inputImage: https://cdn.wiro.ai/uploads/sampleinputs/alibaba-wan-2-7-image-sampleinput-2.jpeg - samples: 1 - enableSequential: false - prompt: Redraw this as a detailed watercolor illustration with visible paper texture and soft bleeding edges, keeping the fox's pose and the composition unchanged. - inputImage: https://cdn.wiro.ai/uploads/sampleinputs/alibaba-wan-2-7-image-sampleinput-3.jpeg - samples: 1 - enableSequential: false - prompt: Cover the whole scene in fresh snow, add falling snowflakes, put warm yellow light in the windows and string lights across the street, and change the sky to dusk. - inputImage: https://cdn.wiro.ai/uploads/sampleinputs/alibaba-wan-2-7-image-sampleinput-4.jpeg - samples: 1 - enableSequential: false - prompt: A cinematic image set following the woman in image 1 through one day in a small California coastal town. Keep her face, hair and clothing consistent in every image. Image 1: early morning, she stands on a wooden pier holding a paper coffee cup, looking out at the flat grey sea, soft blue light and mist. Image 2: midday, she walks along a sunlit street of pastel storefronts, hands in her pockets, palm shadows across the pavement. Image 3: late afternoon, she sits on warm sand with her knees up, sunglasses pushed into her hair, watching the waves, warm golden light. Image 4: sunset, she leans on a railing above the beach with the orange sky behind her and the wind lifting her hair. Photorealistic, natural film colors, 35mm. - inputImage: https://cdn.wiro.ai/uploads/sampleinputs/alibaba-wan-2-7-image-sampleinput-5.jpeg - samples: 4 - enableSequential: true ## Integration Header Prepare ```bash # Sign up Wiro dashboard and create project export YOUR_API_KEY="{{useSelectedProjectAPIKey}}"; export YOUR_API_SECRET="XXXXXXXXX"; # unix time or any random integer value export NONCE=$(date +%s); # hmac-SHA256 (YOUR_API_SECRET+Nonce) with YOUR_API_KEY export SIGNATURE="$(echo -n "${YOUR_API_SECRET}${NONCE}" | openssl dgst -sha256 -hmac "${YOUR_API_KEY}" | awk '{print $NF}')"; ``` ## Run Command - Make HTTP Post Request ```bash curl -X POST "https://api.wiro.ai/v1/Run/alibaba/wan-2-7-image" -H "Content-Type: multipart/form-data" -H "x-api-key: ${YOUR_API_KEY}" -H "x-nonce: ${NONCE}" -H "x-signature: ${SIGNATURE}" -d '{ "inputImage": "alibaba-wan-2-7-image-sampleinput-5.jpeg", "prompt": "A cinematic image set following the woman in image 1 through one day in a small California coastal town. Keep her face, hair and clothing consistent in every image. Image 1: early morning, she stands on a wooden pier holding a paper coffee cup, looking out at the flat grey sea, soft blue light and mist. Image 2: midday, she walks along a sunlit street of pastel storefronts, hands in her pockets, palm shadows across the pavement. Image 3: late afternoon, she sits on warm sand with her knees up, sunglasses pushed into her hair, watching the waves, warm golden light. Image 4: sunset, she leans on a railing above the beach with the orange sky behind her and the wind lifting her hair. Photorealistic, natural film colors, 35mm.", "size": "1K", "samples": 1, "enableSequential": "false", "thinkingMode": "true", "seed": null, "callbackUrl": "You can provide a callback URL; Wiro will send a POST request to it when the task is completed." }'; ``` ## Run Command - Response ```json { "errors": [], "taskid": "2221", "socketaccesstoken": "eDcCm5yyUfIvMFspTwww49OUfgXkQt", "result": true } ``` ## Get Task Detail - Make HTTP Post Request with Task ID ```bash curl -X POST "https://api.wiro.ai/v1/Task/Detail" -H "Content-Type: multipart/form-data" -H "x-api-key: ${YOUR_API_KEY}" -H "x-nonce: ${NONCE}" -H "x-signature: ${SIGNATURE}" -d '{ "taskid": "2221" }'; ``` ## Get Task Detail - Make HTTP Post Request with Socket Access Token ```bash curl -X POST "https://api.wiro.ai/v1/Task/Detail" -H "Content-Type: multipart/form-data" -H "x-api-key: ${YOUR_API_KEY}" -H "x-nonce: ${NONCE}" -H "x-signature: ${SIGNATURE}" -d '{ "tasktoken": "eDcCm5yyUfIvMFspTwww49OUfgXkQt" }'; ``` ## Get Task Detail - Response ```json { "total": "1", "errors": [], "tasklist": [ { "id": "2221", "uuid": "15bce51f-442f-4f44-a71d-13c6374a62bd", "socketaccesstoken": "eDcCm5yyUfIvMFspTwww49OUfgXkQt", "parameters": {}, "debugoutput": "", "debugerror": "", "starttime": "1734513809", "endtime": "1734513813", "elapsedseconds": "6.0000", "status": "task_postprocess_end", "createtime": "1734513807", "canceltime": "0", "assigntime": "1734513807", "accepttime": "1734513807", "preprocessstarttime": "1734513807", "preprocessendtime": "1734513807", "postprocessstarttime": "1734513813", "postprocessendtime": "1734513814", "outputs": [ { "id": "6bc392c93856dfce3a7d1b4261e15af3", "name": "0.png", "contenttype": "image/png", "parentid": "6c1833f39da71e6175bf292b18779baf", "uuid": "15bce51f-442f-4f44-a71d-13c6374a62bd", "size": "202472", "addedtime": "1734513812", "modifiedtime": "1734513812", "accesskey": "dFKlMApaSgMeHKsJyaDeKrefcHahUK", "url": "https://cdn1.wiro.ai/6a6af820-c5050aee-40bd7b83-a2e186c6-7f61f7da-3894e49c-fc0eeb66-9b500fe2/0.png" } ], "size": "202472" } ], "result": true } ``` ## Kill Task - Make HTTP Post Request with Task ID ```bash curl -X POST "https://api.wiro.ai/v1/Task/Kill" -H "Content-Type: multipart/form-data" -H "x-api-key: ${YOUR_API_KEY}" -H "x-nonce: ${NONCE}" -H "x-signature: ${SIGNATURE}" -d '{ "taskid": "534574" }'; ``` ## Kill Task - Make HTTP Post Request with Socket Access Token ```bash curl -X POST "https://api.wiro.ai/v1/Task/Kill" -H "Content-Type: multipart/form-data" -H "x-api-key: ${YOUR_API_KEY}" -H "x-nonce: ${NONCE}" -H "x-signature: ${SIGNATURE}" -d '{ "socketaccesstoken": "ZpYote30on42O4jjHXNiKmrWAZqbRE" }'; ``` ## Kill Task - Response ```json { "errors": [], "tasklist": [ { "id": "534574", "uuid": "15bce51f-442f-4f44-a71d-13c6374a62bd", "name": "", "socketaccesstoken": "ZpYote30on42O4jjHXNiKmrWAZqbRE", "parameters": { "inputImage": "https://api.wiro.ai/v1/File/mCmUXgZLG1FNjjjwmbtPFr2LVJA112/inputImage-6060136.png" }, "debugoutput": "", "debugerror": "", "starttime": "1734513809", "endtime": "1734513813", "elapsedseconds": "6.0000", "status": "task_cancel", "cps": "0.000585000000", "totalcost": "0.003510000000", "guestid": null, "projectid": "699", "modelid": "598", "description": "", "basemodelid": "0", "runtype": "model", "modelfolderid": "", "modelfileid": "", "callbackurl": "", "marketplaceid": null, "createtime": "1734513807", "canceltime": "0", "assigntime": "1734513807", "accepttime": "1734513807", "preprocessstarttime": "1734513807", "preprocessendtime": "1734513807", "postprocessstarttime": "1734513813", "postprocessendtime": "1734513814", "pexit": "0", "categories": "["tool","image-to-image","quick-showcase","compare-landscape"]", "outputs": [ { "id": "6bc392c93856dfce3a7d1b4261e15af3", "name": "0.png", "contenttype": "image/png", "parentid": "6c1833f39da71e6175bf292b18779baf", "uuid": "15bce51f-442f-4f44-a71d-13c6374a62bd", "size": "202472", "addedtime": "1734513812", "modifiedtime": "1734513812", "accesskey": "dFKlMApaSgMeHKsJyaDeKrefcHahUK", "foldercount": "0", "filecount": "0", "ispublic": 0, "expiretime": null, "url": "https://cdn1.wiro.ai/6a6af820-c5050aee-40bd7b83-a2e186c6-7f61f7da-3894e49c-fc0eeb66-9b500fe2/0.png" } ], "size": "202472" } ], "result": true } ``` ## Cancel Task - Make HTTP Post Request (For tasks on queue) ```bash curl -X POST "https://api.wiro.ai/v1/Task/Cancel" -H "Content-Type: multipart/form-data" -H "x-api-key: ${YOUR_API_KEY}" -H "x-nonce: ${NONCE}" -H "x-signature: ${SIGNATURE}" -d '{ "taskid": "634574" }'; ``` ## Cancel Task - Response ```json { "errors": [], "tasklist": [ { "id": "634574", "uuid": "15bce51f-442f-4f44-a71d-13c6374a62bd", "name": "", "socketaccesstoken": "ZpYote30on42O4jjHXNiKmrWAZqbRE", "parameters": { "inputImage": "https://api.wiro.ai/v1/File/mCmUXgZLG1FNjjjwmbtPFr2LVJA112/inputImage-6060136.png" }, "debugoutput": "", "debugerror": "", "starttime": "1734513809", "endtime": "1734513813", "elapsedseconds": "6.0000", "status": "task_cancel", "cps": "0.000585000000", "totalcost": "0.003510000000", "guestid": null, "projectid": "699", "modelid": "598", "description": "", "basemodelid": "0", "runtype": "model", "modelfolderid": "", "modelfileid": "", "callbackurl": "", "marketplaceid": null, "createtime": "1734513807", "canceltime": "0", "assigntime": "1734513807", "accepttime": "1734513807", "preprocessstarttime": "1734513807", "preprocessendtime": "1734513807", "postprocessstarttime": "1734513813", "postprocessendtime": "1734513814", "pexit": "0", "categories": "["tool","image-to-image","quick-showcase","compare-landscape"]", "outputs": [ { "id": "6bc392c93856dfce3a7d1b4261e15af3", "name": "0.png", "contenttype": "image/png", "parentid": "6c1833f39da71e6175bf292b18779baf", "uuid": "15bce51f-442f-4f44-a71d-13c6374a62bd", "size": "202472", "addedtime": "1734513812", "modifiedtime": "1734513812", "accesskey": "dFKlMApaSgMeHKsJyaDeKrefcHahUK", "foldercount": "0", "filecount": "0", "ispublic": 0, "expiretime": null, "url": "https://cdn1.wiro.ai/6a6af820-c5050aee-40bd7b83-a2e186c6-7f61f7da-3894e49c-fc0eeb66-9b500fe2/0.png" } ], "size": "202472" } ], "result": true } ``` ## Task Status Information This section defines the possible task status values returned by the API when polling for task completion. ### Completed Task Statuses (Polling can stop) These indicate that the task has reached a terminal state — either success or failure. Once any of these is received, polling should stop. - task_postprocess_end : Task completed successfully and post-processing is done. - task_cancel : Task was cancelled by the user or system. ### Running Task Statuses (Continue polling) These statuses indicate that the task is still in progress. Polling should continue if one of these is returned. - task_queue : Task is waiting in the queue. - task_accept : Task has been accepted for processing. - task_assign : Task is being assigned to a worker. - task_preprocess_start : Preprocessing is starting. - task_preprocess_end : Preprocessing is complete. - task_start : Task execution has started. - task_output : Output is being generated.