Retrieve a model
One model or preset with input_schema, the JSON Schema (2020-12) of the input it takes. Build your request from it: required fields, allowed values and defaults are all there, and unknown fields are refused.
Needs an API key with the generations:read scope.
curl --request GET \
--url https://api.tryleap.ai/v1/models/{creator}/{name} \
--header 'x-api-key: <api-key>'const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.tryleap.ai/v1/models/{creator}/{name}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.tryleap.ai/v1/models/{creator}/{name}"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text){
"id": "black-forest-labs/flux-2-pro",
"object": "model",
"type": "model",
"name": "FLUX.2 [pro]",
"creator": "Black Forest Labs",
"modality": "image",
"tasks": [
"text-to-image"
],
"description": "Black Forest Labs' second generation: sharper detail and text than FLUX1.1, at a lower price.",
"revision": "2026-10-02",
"version": null,
"latest": true,
"status": "stable",
"deprecation": null,
"pricing": {
"unit": "image",
"usd": "0.033",
"overrides": [],
"drivers": [
"n"
]
},
"input_schema": {
"type": "object",
"additionalProperties": false,
"required": [
"prompt"
],
"properties": {
"prompt": {
"type": "string",
"pattern": "\\S"
},
"aspect_ratio": {
"type": "string",
"enum": [
"1:1",
"3:2",
"2:3",
"4:3",
"3:4",
"16:9",
"9:16",
"21:9",
"9:21"
],
"default": "1:1"
},
"n": {
"type": "integer",
"minimum": 1,
"maximum": 4,
"default": 1
},
"seed": {
"type": "integer",
"minimum": 0,
"maximum": 4294967295
}
}
}
}{
"error": {
"type": "invalid_request_error",
"code": "conflicting_credentials",
"message": "Send one API key.",
"param": null,
"doc_url": null,
"request_id": "req_8kQ2vX9mR4tL6nB1cW3yZ5aD"
}
}{
"error": {
"type": "authentication_error",
"code": "authentication_required",
"message": "Authentication is required.",
"param": null,
"doc_url": null,
"request_id": "req_8kQ2vX9mR4tL6nB1cW3yZ5aD"
}
}{
"error": {
"type": "permission_error",
"code": "permission_denied",
"message": "Permission denied.",
"param": null,
"doc_url": null,
"request_id": "req_8kQ2vX9mR4tL6nB1cW3yZ5aD"
}
}{
"error": {
"type": "invalid_request_error",
"code": "resource_not_found",
"message": "That resource does not exist.",
"param": null,
"doc_url": null,
"request_id": "req_8kQ2vX9mR4tL6nB1cW3yZ5aD"
}
}{
"error": {
"type": "invalid_request_error",
"code": "gone",
"message": "That resource was retired.",
"param": null,
"doc_url": null,
"request_id": "req_8kQ2vX9mR4tL6nB1cW3yZ5aD"
}
}{
"error": {
"type": "rate_limit_error",
"code": "rate_limit_exceeded",
"message": "Too Many Requests",
"param": null,
"doc_url": null,
"request_id": "req_8kQ2vX9mR4tL6nB1cW3yZ5aD"
}
}Authorizations
Your workspace API key, leap_.... Create one at https://app.tryleap.ai/go/api, and keep it on your server.
Path Parameters
The first part of the model ID, such as black-forest-labs or leap.
The second part, such as flux-2-pro, or restore-photo@1 for a preset.
Response
The model and its input schema.
A model or preset with the JSON Schema of its input.
The ID to run it by: creator/name for a model, leap/name@N for a preset.
100^[a-z0-9][a-z0-9-]*\/[a-z0-9][a-z0-9.-]*(@[1-9][0-9]{0,3})?$"model"model for a raw model, preset for a ready-made recipe built on one.
model, preset Its display name.
Who made it.
What it makes: image, video, audio, 3d or text.
image, video, audio, 3d, text What it does, main task first, such as text-to-image or image-to-video.
text-to-image, image-edit, outpaint, upscale-image, remove-background, try-on, text-to-video, image-to-video, video-to-video, upscale-video, lip-sync, talking-avatar, text-to-speech, voice-clone, text-to-music, sound-effects, image-to-3d, text-to-3d, video-to-audio, speech-to-speech, motion-transfer, speech-to-text, captions What it's good at, in a sentence.
The date of its current schema and price.
^\d{4}-\d{2}-\d{2}$A preset's version, the N in @N; null for a model.
0 < x <= 9007199254740991Whether a preset ID without @N runs this version. Always true for a model.
preview (may still change), stable, deprecated (runs until its sunset) or retired (doesn't run).
preview, stable, deprecated, retired When and why it's going away; null unless it's deprecated.
Show child attributes
Show child attributes
Show child attributes
Show child attributes
A JSON Schema (2020-12) of the input it takes: required fields, types, allowed values and defaults. Unknown fields are refused, and a field that takes a file has the pattern ^file_[0-9A-Za-z]{24}$.
^\d{4}-\d{2}-\d{2}$Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
curl --request GET \
--url https://api.tryleap.ai/v1/models/{creator}/{name} \
--header 'x-api-key: <api-key>'const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://api.tryleap.ai/v1/models/{creator}/{name}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.tryleap.ai/v1/models/{creator}/{name}"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text){
"id": "black-forest-labs/flux-2-pro",
"object": "model",
"type": "model",
"name": "FLUX.2 [pro]",
"creator": "Black Forest Labs",
"modality": "image",
"tasks": [
"text-to-image"
],
"description": "Black Forest Labs' second generation: sharper detail and text than FLUX1.1, at a lower price.",
"revision": "2026-10-02",
"version": null,
"latest": true,
"status": "stable",
"deprecation": null,
"pricing": {
"unit": "image",
"usd": "0.033",
"overrides": [],
"drivers": [
"n"
]
},
"input_schema": {
"type": "object",
"additionalProperties": false,
"required": [
"prompt"
],
"properties": {
"prompt": {
"type": "string",
"pattern": "\\S"
},
"aspect_ratio": {
"type": "string",
"enum": [
"1:1",
"3:2",
"2:3",
"4:3",
"3:4",
"16:9",
"9:16",
"21:9",
"9:21"
],
"default": "1:1"
},
"n": {
"type": "integer",
"minimum": 1,
"maximum": 4,
"default": 1
},
"seed": {
"type": "integer",
"minimum": 0,
"maximum": 4294967295
}
}
}
}{
"error": {
"type": "invalid_request_error",
"code": "conflicting_credentials",
"message": "Send one API key.",
"param": null,
"doc_url": null,
"request_id": "req_8kQ2vX9mR4tL6nB1cW3yZ5aD"
}
}{
"error": {
"type": "authentication_error",
"code": "authentication_required",
"message": "Authentication is required.",
"param": null,
"doc_url": null,
"request_id": "req_8kQ2vX9mR4tL6nB1cW3yZ5aD"
}
}{
"error": {
"type": "permission_error",
"code": "permission_denied",
"message": "Permission denied.",
"param": null,
"doc_url": null,
"request_id": "req_8kQ2vX9mR4tL6nB1cW3yZ5aD"
}
}{
"error": {
"type": "invalid_request_error",
"code": "resource_not_found",
"message": "That resource does not exist.",
"param": null,
"doc_url": null,
"request_id": "req_8kQ2vX9mR4tL6nB1cW3yZ5aD"
}
}{
"error": {
"type": "invalid_request_error",
"code": "gone",
"message": "That resource was retired.",
"param": null,
"doc_url": null,
"request_id": "req_8kQ2vX9mR4tL6nB1cW3yZ5aD"
}
}{
"error": {
"type": "rate_limit_error",
"code": "rate_limit_exceeded",
"message": "Too Many Requests",
"param": null,
"doc_url": null,
"request_id": "req_8kQ2vX9mR4tL6nB1cW3yZ5aD"
}
}