Get Diffusion Task Status
curl --request GET \
--url https://api.mulerouter.ai/vendors/midjourney/v1/tob/diffusion/{task_id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.mulerouter.ai/vendors/midjourney/v1/tob/diffusion/{task_id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.mulerouter.ai/vendors/midjourney/v1/tob/diffusion/{task_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.mulerouter.ai/vendors/midjourney/v1/tob/diffusion/{task_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.mulerouter.ai/vendors/midjourney/v1/tob/diffusion/{task_id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.mulerouter.ai/vendors/midjourney/v1/tob/diffusion/{task_id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.mulerouter.ai/vendors/midjourney/v1/tob/diffusion/{task_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"images": [
"https://mulerouter.muleusercontent.com/public/079c5ad5-3b81-4eee-af06-4d85029899d0-1.png",
"https://mulerouter.muleusercontent.com/public/079c5ad5-3b81-4eee-af06-4d85029899d0-2.png",
"https://mulerouter.muleusercontent.com/public/079c5ad5-3b81-4eee-af06-4d85029899d0-3.png",
"https://mulerouter.muleusercontent.com/public/079c5ad5-3b81-4eee-af06-4d85029899d0-4.png"
],
"task_info": {
"id": "079c5ad5-3b81-4eee-af06-4d85029899d0",
"status": "completed",
"created_at": "2025-09-21T00:00:00.000Z",
"updated_at": "2025-09-21T00:00:00.000Z"
}
}{
"task_info": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "pending",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"error": {
"code": 3001,
"title": "Task Execution Error",
"detail": "Task execution failed"
}
}
}Midjourney
Diffusion
Retrieve the status and results of a text-to-image generation task.
GET
/
vendors
/
midjourney
/
v1
/
tob
/
diffusion
/
{task_id}
Get Diffusion Task Status
curl --request GET \
--url https://api.mulerouter.ai/vendors/midjourney/v1/tob/diffusion/{task_id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.mulerouter.ai/vendors/midjourney/v1/tob/diffusion/{task_id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.mulerouter.ai/vendors/midjourney/v1/tob/diffusion/{task_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.mulerouter.ai/vendors/midjourney/v1/tob/diffusion/{task_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.mulerouter.ai/vendors/midjourney/v1/tob/diffusion/{task_id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.mulerouter.ai/vendors/midjourney/v1/tob/diffusion/{task_id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.mulerouter.ai/vendors/midjourney/v1/tob/diffusion/{task_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"images": [
"https://mulerouter.muleusercontent.com/public/079c5ad5-3b81-4eee-af06-4d85029899d0-1.png",
"https://mulerouter.muleusercontent.com/public/079c5ad5-3b81-4eee-af06-4d85029899d0-2.png",
"https://mulerouter.muleusercontent.com/public/079c5ad5-3b81-4eee-af06-4d85029899d0-3.png",
"https://mulerouter.muleusercontent.com/public/079c5ad5-3b81-4eee-af06-4d85029899d0-4.png"
],
"task_info": {
"id": "079c5ad5-3b81-4eee-af06-4d85029899d0",
"status": "completed",
"created_at": "2025-09-21T00:00:00.000Z",
"updated_at": "2025-09-21T00:00:00.000Z"
}
}{
"task_info": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "pending",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"error": {
"code": 3001,
"title": "Task Execution Error",
"detail": "Task execution failed"
}
}
}The
prompt parameter is compatible with Midjourney’s format. Please refer to Midjourney’s official documentation for more details.Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
The UUID of the task to retrieve
Response
Task completed successfully
Show child attributes
Show child attributes
List of generated image URLs
URL of the generated image
Example:
[
"https://mulerouter.muleusercontent.com/public/079c5ad5-3b81-4eee-af06-4d85029899d0-1.png",
"https://mulerouter.muleusercontent.com/public/079c5ad5-3b81-4eee-af06-4d85029899d0-2.png",
"https://mulerouter.muleusercontent.com/public/079c5ad5-3b81-4eee-af06-4d85029899d0-3.png",
"https://mulerouter.muleusercontent.com/public/079c5ad5-3b81-4eee-af06-4d85029899d0-4.png"
]
⌘I

