import requests
url = "https://api.fireworks.ai/inference/v1/workflows/accounts/fireworks/models/{model}"
headers = {
"Content-Type": "application/json",
"Authorization": "Bearer $API_KEY",
}
data = {
"prompt": "A beautiful sunset over the ocean",
"input_image": "<string>",
"seed": 42,
"aspect_ratio": "<string>",
"output_format": "jpeg",
"webhook_url": "<string>",
"webhook_secret": "<string>",
"prompt_upsampling": False,
"safety_tolerance": 2
}
response = requests.post(url, headers=headers, json=data)
import requests
url = "https://api.fireworks.ai/inference/v1/workflows/accounts/fireworks/models/{model}"
headers = {
"Content-Type": "application/json",
"Authorization": "Bearer $API_KEY",
}
data = {
"prompt": "A beautiful sunset over the ocean",
"input_image": "<string>",
"seed": 42,
"aspect_ratio": "<string>",
"output_format": "jpeg",
"webhook_url": "<string>",
"webhook_secret": "<string>",
"prompt_upsampling": False,
"safety_tolerance": 2
}
response = requests.post(url, headers=headers, json=data)
jpeg, pngimport requests
url = "https://api.fireworks.ai/inference/v1/workflows/accounts/fireworks/models/{model}"
headers = {
"Content-Type": "application/json",
"Authorization": "Bearer $API_KEY",
}
data = {
"prompt": "A beautiful sunset over the ocean",
"input_image": "<string>",
"seed": 42,
"aspect_ratio": "<string>",
"output_format": "jpeg",
"webhook_url": "<string>",
"webhook_secret": "<string>",
"prompt_upsampling": False,
"safety_tolerance": 2
}
response = requests.post(url, headers=headers, json=data)
Was this page helpful?