GlianaAI (1)
Download OpenAPI specification:
Pay-per-call AI inference across generative-media models. No signup or API key; each call is settled over MPP. Per-model prices: GET /v1/price?model=. Rate limit ~120 requests/min per IP — need more? contact@glianalabs.com.
Run any of 90+ generative models pay-per-call.
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
One endpoint for the whole catalog: send { model, ...modelInput } — pick any model from GET /v1/models (90+ across image, video, image-to-video, text-to-speech, speech-to-text, music). Responds 402 Payment Required with the per-model price; pay from your own account and retry.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id (see GET /v1/models). |
| prompt | string Most models take a text prompt; STT/some take a file/url instead. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "grok-imagine-image",
- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Run any of 90+ models over a payment channel (pay-as-you-go).
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Open one Tempo channel and pay many calls with off-chain vouchers; settle on close. Non-custodial — the deposit stays in the on-chain escrow.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "string"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Run any of 90+ generative models pay-per-call.
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
One endpoint for the whole catalog: send { model, ...modelInput } — pick any model from GET /v1/models (90+ across image, video, image-to-video, text-to-speech, speech-to-text, music). Responds 402 Payment Required with the per-model price; pay from your own account and retry.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id (see GET /v1/models). |
| prompt | string Most models take a text prompt; STT/some take a file/url instead. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "grok-imagine-image",
- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Generate a video from a text prompt or an image.
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Capability endpoint — pick any matching model with GET /v1/models and pass it as { model }. Same pay-per-call charge as /v1/infer (402, then pay and retry); the per-model POST /x402/wan-2.7-i2v path also works.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id (see GET /v1/models). |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "wan-2.7-i2v",
- "prompt": "a timelapse of clouds over mountains"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Run any of 90+ models over a payment channel (pay-as-you-go).
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Open one Tempo channel and pay many calls with off-chain vouchers; settle on close. Non-custodial — the deposit stays in the on-chain escrow.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "string"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Generate a video with wan-2.7-i2v via x402.
$0.360000–$2.700000 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call wan-2.7-i2v (image-to-video). Priced per second ($0.180000/sec) — final price = video length x rate (duration 2-15s).
Request Body schema: application/jsonrequired
| duration | integer [ 2 .. 15 ] Length of the output in seconds. |
| image required | string Input image (HTTPS URL or upload) to guide or edit from. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| negative_prompt | string What to avoid in the output. |
| prompt | string Text prompt describing what to generate. |
| resolution | string Enum: "720P" "1080P" Output resolution / quality tier. |
| seed | integer [ 0 .. 2147483647 ] Random seed for reproducible results — same seed + inputs gives the same output. |
| watermark | boolean Whether to add a watermark to the output. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate a video with hh1-i2v via x402.
$1.218000–$6.090000 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call hh1-i2v (image-to-video). Priced per second ($0.406000/sec) — final price = video length x rate (duration 3-15s).
Request Body schema: application/jsonrequired
| duration | integer [ 3 .. 15 ] Length of the output in seconds. |
| image required | string Input image (HTTPS URL or upload) to guide or edit from. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| negative_prompt | string What to avoid in the output. |
| prompt | string Text prompt describing what to generate. |
| resolution | string Enum: "720P" "1080P" Output resolution / quality tier. |
| seed | integer [ 0 .. 2147483647 ] Random seed for reproducible results — same seed + inputs gives the same output. |
| watermark | boolean Whether to add a watermark to the output. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate a video with hh1.1-i2v via x402.
$0.783000–$3.915000 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call hh1.1-i2v (image-to-video). Priced per second ($0.261000/sec) — final price = video length x rate (duration 3-15s).
Request Body schema: application/jsonrequired
| image required | string Input image (HTTPS URL or upload) to guide or edit from. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| prompt | string Text prompt describing what to generate. |
| negative_prompt | string What to avoid in the output. |
| resolution | string Enum: "720P" "1080P" Output resolution / quality tier. |
| duration | integer [ 3 .. 15 ] Length of the output in seconds. |
| seed | integer [ 0 .. 2147483647 ] Random seed for reproducible results — same seed + inputs gives the same output. |
| watermark | boolean Whether to add a watermark to the output. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate a video with hh1.1-r2v via x402.
$0.783000–$3.915000 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call hh1.1-r2v (image-to-video). Priced per second ($0.261000/sec) — final price = video length x rate (duration 3-15s).
Request Body schema: application/jsonrequired
| prompt required | string Text prompt describing what to generate. |
| images required | Array of strings <uri> [ items <uri > ] Reference images to guide generation. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| resolution | string Enum: "720P" "1080P" Output resolution / quality tier. |
| ratio | string Enum: "16:9" "9:16" "3:4" "4:3" "1:1" "21:9" "9:21" "5:4" "4:5" Output aspect ratio. |
| duration | integer [ 3 .. 15 ] Length of the output in seconds. |
| seed | integer [ 0 .. 2147483647 ] Random seed for reproducible results — same seed + inputs gives the same output. |
| watermark | boolean Whether to add a watermark to the output. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table",
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate a video with hailuo-2.3-fast via x402.
$0.079750–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call hailuo-2.3-fast (image-to-video). Priced per second ($0.079750/sec) — final price = video length x rate.
Request Body schema: application/jsonrequired
| duration | number Enum: 6 10 Length of the output in seconds. |
| fast_pretreatment | boolean Faster input pre-processing (may trade a little quality for speed). |
| first_frame_image required | string URL or base64 data URI of the first frame image Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| prompt | string Text prompt describing what to generate. |
| prompt_optimizer | boolean Let the model automatically optimize your prompt. |
| resolution | string Enum: "768P" "1080P" Output resolution / quality tier. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Run any of 90+ generative models pay-per-call.
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
One endpoint for the whole catalog: send { model, ...modelInput } — pick any model from GET /v1/models (90+ across image, video, image-to-video, text-to-speech, speech-to-text, music). Responds 402 Payment Required with the per-model price; pay from your own account and retry.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id (see GET /v1/models). |
| prompt | string Most models take a text prompt; STT/some take a file/url instead. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "grok-imagine-image",
- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Generate music from a text prompt with any model.
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Capability endpoint — pick any matching model with GET /v1/models and pass it as { model }. Same pay-per-call charge as /v1/infer (402, then pay and retry); the per-model POST /x402/music-2.6 path also works.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id (see GET /v1/models). |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "music-2.6",
- "prompt": "a calm lo-fi beat"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Run any of 90+ models over a payment channel (pay-as-you-go).
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Open one Tempo channel and pay many calls with off-chain vouchers; settle on close. Non-custodial — the deposit stays in the on-chain escrow.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "string"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Generate music with music-2.6 via x402.
$0.192000 per call. Flat price, charged only on success.
Pay-per-call music-2.6 (music).
Request Body schema: application/jsonrequired
| bitrate | number Enum: 32000 64000 128000 256000 Audio bitrate |
| format | string Enum: "mp3" "wav" Audio format |
| is_instrumental | boolean Generate instrumental music (no vocals) |
| lyrics | string Song lyrics, using \n to separate lines |
| lyrics_optimizer | boolean Automatically generate lyrics based on the prompt description |
| prompt required | string Description of the music style, mood, and scenario |
| sample_rate | number Enum: 16000 24000 32000 44100 Audio sample rate |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate music with music-v2 via x402.
$0.003000–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call music-v2 (music). Priced per second ($0.003000/sec) — final price = video length x rate.
Request Body schema: application/jsonrequired
| prompt | string Text prompt describing what to generate. |
| composition_plan | object |
| music_length_ms | integer [ 3000 .. 600000 ] |
| output_format | string Enum: "auto" "mp3_48000_128" "mp3_48000_192" "mp3_48000_240" "mp3_48000_320" "mp3_22050_32" "mp3_24000_48" "mp3_44100_32" "mp3_44100_64" "mp3_44100_96" "mp3_44100_128" "mp3_44100_192" "opus_48000_32" "opus_48000_64" "opus_48000_96" "opus_48000_128" "opus_48000_192" File format of the output (e.g. png, jpeg, mp4). |
| seed | integer [ 0 .. 4294967295 ] Random seed for reproducible results — same seed + inputs gives the same output. |
| force_instrumental | boolean |
| store_for_inpainting | boolean |
| sign_with_c2pa | boolean |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Run any of 90+ generative models pay-per-call.
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
One endpoint for the whole catalog: send { model, ...modelInput } — pick any model from GET /v1/models (90+ across image, video, image-to-video, text-to-speech, speech-to-text, music). Responds 402 Payment Required with the per-model price; pay from your own account and retry.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id (see GET /v1/models). |
| prompt | string Most models take a text prompt; STT/some take a file/url instead. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "grok-imagine-image",
- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Transcribe audio to text with any STT model.
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Capability endpoint — pick any matching model with GET /v1/models and pass it as { model }. Same pay-per-call charge as /v1/infer (402, then pay and retry); the per-model POST /x402/grok-stt path also works. FILE INPUT: if the image is already on the web or your own storage, pass image_url — we fetch it server-side at datacenter speed, which is the fastest option by far. Sending it inline as image_base64 is simplest and stores nothing anywhere, but base64 adds ~33% to the bytes and you pay your own upload speed, so it is best under ~1MB. For a large local file, upload the RAW bytes to POST /v1/media (free, ≤40MB) and pass the URL: same transfer as base64 minus the 33%, and identity endpoints delete the object as soon as they have read it.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id (see GET /v1/models). |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "grok-stt",
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Run any of 90+ models over a payment channel (pay-as-you-go).
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Open one Tempo channel and pay many calls with off-chain vouchers; settle on close. Non-custodial — the deposit stays in the on-chain escrow.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "string"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Transcribe audio with grok-stt via x402.
$0.009006 per call. Flat price, charged only on success.
Pay-per-call grok-stt (stt).
Request Body schema: application/jsonrequired
| audio_format | string Enum: "pcm" "mulaw" "alaw" Format hint for raw/headerless audio. Required for pcm, mulaw, alaw. Omit for container formats (mp3, wav, etc.) — xAI auto-detects them. |
| channels | integer [ 2 .. 8 ] Number of audio channels (2–8). Required only for multichannel raw audio; auto-detected for container formats. |
| diarize | boolean When true, enables speaker diarization. Each word in the response includes a |
| file | string Audio file as a data URI (data:audio/...;base64,...) or an HTTPS URL the gateway fetches and uploads. Supported container formats: flac, mp3, mp4, m4a, mkv, ogg, opus, wav, aac. Raw formats (pcm, mulaw, alaw) also accepted — supply audio_format and sample_rate. Gateway-side size limit: 25 MB. Mutually exclusive with |
| filler_words | boolean When true, filler words (uh, um, er) are included in the transcript. Defaults to false — filler words are removed. |
| format | boolean When true, enables Inverse Text Normalization — spoken numbers and currencies are converted to written form (e.g. "one hundred dollars" → "$100"). Requires language to be set. |
| keyterm | Array of arrays Key terms to bias transcription toward (e.g. product names, proper nouns). Each term up to 50 characters, max 100 terms. Sent as repeated form fields: keyterm=Term+One&keyterm=Term+Two. |
| language | string Language code (e.g. "en", "fr", "de"). Used with format=true to enable Inverse Text Normalization. xAI transcribes in any language regardless — supplying this enables number/currency formatting in the transcript. |
| multichannel | boolean When true, each audio channel is transcribed independently. Results are returned in the |
| sample_rate | integer Sample rate in Hz. Required when audio_format is set. |
| url | string HTTPS URL of an audio file for xAI to fetch server-side. Mutually exclusive with |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{ }Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Transcribe audio with gpt-4o-transcribe via x402.
$0.032400 per call. Flat price, charged only on success.
Pay-per-call gpt-4o-transcribe (stt).
Request Body schema: application/jsonrequired
| file required | string The audio file as a data URI (data:audio/...;base64,...) or HTTPS URL. Supported formats: flac, mp3, mp4, mpeg, mpga, m4a, ogg, wav, webm. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| language | string The language of the input audio. Supplying the input language in ISO-639-1 format will improve accuracy and latency. |
| prompt | string An optional text to guide the model's style or continue a previous audio segment. The prompt should match the audio language. |
| temperature | number [ 0 .. 1 ] The sampling temperature, between 0 and 1. Higher values like 0.8 will make the output more random, while lower values like 0.2 will make it more focused and deterministic. Defaults to 0 if omitted. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Transcribe audio with universal-3-pro via x402.
$0.018900 per call. Flat price, charged only on success.
Pay-per-call universal-3-pro (stt).
Request Body schema: application/jsonrequired
| audio_end_at | integer >= 0 Timestamp (in milliseconds) to end transcription at. |
| audio_start_from | integer >= 0 Timestamp (in milliseconds) to start transcription from. |
| audio_url required | string The URL of the audio file to transcribe. Can be a publicly accessible URL or a data URI (data:audio/...;base64,...). For data URIs, the audio will be uploaded to AssemblyAI automatically. Required for pre-recorded transcription (when stream is false or not set). Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| auto_chapters | boolean Enable automatic chapter detection. |
| auto_highlights | boolean Enable automatic extraction of key phrases and highlights. |
| boost_param | string Enum: "low" "default" "high" How much to boost the words in word_boost. |
| content_safety | boolean Enable content safety detection for sensitive content. |
| custom_spelling | Array of arrays Custom spelling rules to replace specific words or phrases in the transcription output. |
| disfluencies | boolean Include filler words like "um", "uh", etc. in the transcript. |
| domain | string Value: "medical-v1" Domain-specific transcription mode. "medical-v1" enables medical terminology optimization. |
| dual_channel | boolean Process audio as dual-channel (stereo) for better accuracy. |
| entity_detection | boolean Enable detection of entities like names, organizations, and locations. |
| filter_profanity | boolean Filter profanity from the transcription. |
| iab_categories | boolean Enable IAB (Interactive Advertising Bureau) content taxonomy classification. |
| keyterms_prompt | Array of arrays An array of up to 1,000 words or phrases (max 6 words per phrase) to improve transcription accuracy. Cannot be used with the prompt parameter. |
| language_code | string The language code for the audio file (e.g., "en", "es", "fr"). Defaults to automatic language detection. |
| language_detection | boolean Enable automatic language detection. When enabled with speech_models, the system will automatically select the best model for the detected language. |
| multichannel | boolean Process each audio channel separately for multi-channel audio files. |
| prompt | string A custom prompt to guide transcription style, formatting, and output characteristics. Maximum 1,500 words. |
| redact_pii | boolean Redact personally identifiable information. |
| redact_pii_audio | boolean Generate a redacted audio file with PII removed. |
| redact_pii_policies | Array of arrays Specific PII policies to apply for redaction. |
| redact_pii_sub | string Enum: "entity_name" "hash" Strategy for substituting redacted PII. |
| sentiment_analysis | boolean Enable sentiment analysis for each sentence. |
| speaker_labels | boolean Enable speaker diarization to identify different speakers in the audio. |
| speakers_expected | integer >= 1 Expected number of speakers for speaker diarization. |
| speech_threshold | number [ 0 .. 1 ] Confidence threshold for speech detection. |
| temperature | number [ 0 .. 1 ] Controls randomness in model output (0.0-1.0). Lower values make output more deterministic. Default is 0.0. |
| webhook_url | string URL to receive webhook notifications when transcription is complete. |
| word_boost | Array of arrays Array of words to boost recognition accuracy (legacy - use keyterms_prompt instead). |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Run any of 90+ generative models pay-per-call.
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
One endpoint for the whole catalog: send { model, ...modelInput } — pick any model from GET /v1/models (90+ across image, video, image-to-video, text-to-speech, speech-to-text, music). Responds 402 Payment Required with the per-model price; pay from your own account and retry.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id (see GET /v1/models). |
| prompt | string Most models take a text prompt; STT/some take a file/url instead. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "grok-imagine-image",
- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Generate an image from a text prompt with any model.
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Capability endpoint — pick any matching model with GET /v1/models and pass it as { model }. Same pay-per-call charge as /v1/infer (402, then pay and retry); the per-model POST /x402/flux-2-pro-preview path also works.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id (see GET /v1/models). |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "flux-2-pro-preview",
- "prompt": "a red apple on a wooden table"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Run any of 90+ models over a payment channel (pay-as-you-go).
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Open one Tempo channel and pay many calls with off-chain vouchers; settle on close. Non-custodial — the deposit stays in the on-chain escrow.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "string"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Generate an image with flux-2-pro-preview via x402.
$0.054000 per call. Flat price, charged only on success.
Pay-per-call flux-2-pro-preview (text-to-image).
Request Body schema: application/jsonrequired
| height | integer >= 64 Height of the generated image in pixels (minimum 64). Omit to let BFL pick. |
| input_images | Array of strings <uri> [ items <uri > ] Up to 8 reference images for editing or multi-image composition. Each entry is an HTTPS URL or a data:image/...;base64,... URI. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| output_format | string Enum: "jpeg" "png" "webp" Output image format. Defaults to jpeg. |
| prompt required | string Text prompt for image generation or editing. |
| safety_tolerance | integer [ 0 .. 5 ] Tolerance for input/output moderation. 0 is the strictest, 5 the most permissive. Defaults to 2. |
| seed | integer Optional seed for reproducible generation. |
| width | integer >= 64 Width of the generated image in pixels (minimum 64). Omit to let BFL pick. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with flux-2-max via x402.
$0.126000 per call. Flat price, charged only on success.
Pay-per-call flux-2-max (text-to-image).
Request Body schema: application/jsonrequired
| height | integer >= 64 Height of the generated image in pixels (minimum 64). Omit to let BFL pick. |
| input_images | Array of strings <uri> [ items <uri > ] Up to 8 reference images for editing or multi-image composition. Each entry is an HTTPS URL or a data:image/...;base64,... URI. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| output_format | string Enum: "jpeg" "png" "webp" Output image format. Defaults to jpeg. |
| prompt required | string Text prompt for image generation or editing. |
| safety_tolerance | integer [ 0 .. 5 ] Tolerance for input/output moderation. 0 is the strictest, 5 the most permissive. Defaults to 2. |
| seed | integer Optional seed for reproducible generation. |
| width | integer >= 64 Width of the generated image in pixels (minimum 64). Omit to let BFL pick. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with flux-2-flex via x402.
$0.090000 per call. Flat price, charged only on success.
Pay-per-call flux-2-flex (text-to-image).
Request Body schema: application/jsonrequired
| guidance | number [ 1.5 .. 10 ] Classifier-free guidance scale (1.5–10). Higher values follow the prompt more strictly at the cost of realism. |
| height | integer >= 64 Height of the generated image in pixels (minimum 64). Omit to let BFL pick. |
| input_images | Array of strings <uri> [ items <uri > ] Up to 8 reference images for editing or multi-image composition. Each entry is an HTTPS URL or a data:image/...;base64,... URI. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| output_format | string Enum: "jpeg" "png" "webp" Output image format. Defaults to jpeg. |
| prompt required | string Text prompt for image generation or editing. |
| prompt_upsampling | boolean Whether BFL should expand short prompts before generation. Defaults to true on flex. |
| safety_tolerance | integer [ 0 .. 5 ] Tolerance for input/output moderation. 0 is the strictest, 5 the most permissive. Defaults to 2. |
| seed | integer Optional seed for reproducible generation. |
| steps | integer [ 1 .. 50 ] Number of denoising steps (1–50). Higher steps yield more detail at the cost of latency. |
| width | integer >= 64 Width of the generated image in pixels (minimum 64). Omit to let BFL pick. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with grok-imagine-image-quality via x402.
$0.060000 per call. Flat price, charged only on success.
Pay-per-call grok-imagine-image-quality (text-to-image).
Request Body schema: application/jsonrequired
| aspect_ratio | string Enum: "1:1" "3:4" "4:3" "9:16" "16:9" "2:3" "3:2" "9:19.5" "19.5:9" "9:20" "20:9" "1:2" "2:1" "auto" Output aspect ratio (e.g. 16:9, 1:1, 9:16). |
| image | object Input image (HTTPS URL or upload) to guide or edit from. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| images | Array of strings <uri> [ items <uri > ] Reference images to guide generation. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| mask | object Mask image marking the region to edit (inpaint). Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| n | integer [ 1 .. 10 ] How many outputs to generate. |
| prompt required | string Text prompt describing what to generate. |
| quality | string Enum: "low" "medium" "high" Output quality level. |
| resolution | string Enum: "1k" "2k" Output resolution / quality tier. |
| response_format | string Enum: "url" "b64_json" How the result is returned (e.g. a URL or base64 data). |
| user | string Optional end-user identifier for abuse monitoring; not required. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with grok-imagine-image via x402.
$0.024000 per call. Flat price, charged only on success.
Pay-per-call grok-imagine-image (text-to-image).
Request Body schema: application/jsonrequired
| aspect_ratio | string Enum: "1:1" "3:4" "4:3" "9:16" "16:9" "2:3" "3:2" "9:19.5" "19.5:9" "9:20" "20:9" "1:2" "2:1" "auto" Output aspect ratio (e.g. 16:9, 1:1, 9:16). |
| image | object Input image (HTTPS URL or upload) to guide or edit from. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| images | Array of strings <uri> [ items <uri > ] Reference images to guide generation. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| mask | object Mask image marking the region to edit (inpaint). Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| n | integer [ 1 .. 10 ] How many outputs to generate. |
| prompt required | string Text prompt describing what to generate. |
| quality | string Enum: "low" "medium" "high" Output quality level. |
| resolution | string Enum: "1k" "2k" Output resolution / quality tier. |
| response_format | string Enum: "url" "b64_json" How the result is returned (e.g. a URL or base64 data). |
| user | string Optional end-user identifier for abuse monitoring; not required. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with recraftv4-pro via x402.
$0.450000 per call. Flat price, charged only on success.
Pay-per-call recraftv4-pro (text-to-image).
Request Body schema: application/jsonrequired
| controls | object Advanced generation controls (style, color, and artistic settings). |
| prompt required | string Text prompt describing what to generate. |
| size | string Output dimensions (width × height). |
| style | string Visual style preset to apply. |
| substyle | string A finer style variant within the chosen style. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with recraftv4-vector via x402.
$0.144000 per call. Flat price, charged only on success.
Pay-per-call recraftv4-vector (text-to-image).
Request Body schema: application/jsonrequired
| controls | object Advanced generation controls (style, color, and artistic settings). |
| prompt required | string Text prompt describing what to generate. |
| size | string Output dimensions (width × height). |
| style | string Visual style preset to apply. |
| substyle | string A finer style variant within the chosen style. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with recraftv4-pro-vector via x402.
$0.540000 per call. Flat price, charged only on success.
Pay-per-call recraftv4-pro-vector (text-to-image).
Request Body schema: application/jsonrequired
| controls | object Advanced generation controls (style, color, and artistic settings). |
| prompt required | string Text prompt describing what to generate. |
| size | string Output dimensions (width × height). |
| style | string Visual style preset to apply. |
| substyle | string A finer style variant within the chosen style. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with recraftv4-1-vector via x402.
$0.144000 per call. Flat price, charged only on success.
Pay-per-call recraftv4-1-vector (text-to-image).
Request Body schema: application/jsonrequired
| controls | object Advanced generation controls (style, color, and artistic settings). |
| prompt required | string Text prompt describing what to generate. |
| size | string Output dimensions (width × height). |
| style | string Visual style preset to apply. |
| substyle | string A finer style variant within the chosen style. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with recraftv4-1-utility-vector via x402.
$0.144000 per call. Flat price, charged only on success.
Pay-per-call recraftv4-1-utility-vector (text-to-image).
Request Body schema: application/jsonrequired
| controls | object Advanced generation controls (style, color, and artistic settings). |
| prompt required | string Text prompt describing what to generate. |
| size | string Output dimensions (width × height). |
| style | string Visual style preset to apply. |
| substyle | string A finer style variant within the chosen style. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with recraftv4-1-utility-pro via x402.
$0.450000 per call. Flat price, charged only on success.
Pay-per-call recraftv4-1-utility-pro (text-to-image).
Request Body schema: application/jsonrequired
| controls | object Advanced generation controls (style, color, and artistic settings). |
| prompt required | string Text prompt describing what to generate. |
| size | string Output dimensions (width × height). |
| style | string Visual style preset to apply. |
| substyle | string A finer style variant within the chosen style. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with recraftv4-1-utility-pro-vector via x402.
$0.540000 per call. Flat price, charged only on success.
Pay-per-call recraftv4-1-utility-pro-vector (text-to-image).
Request Body schema: application/jsonrequired
| controls | object Advanced generation controls (style, color, and artistic settings). |
| prompt required | string Text prompt describing what to generate. |
| size | string Output dimensions (width × height). |
| style | string Visual style preset to apply. |
| substyle | string A finer style variant within the chosen style. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with recraftv4-1-pro-vector via x402.
$0.540000 per call. Flat price, charged only on success.
Pay-per-call recraftv4-1-pro-vector (text-to-image).
Request Body schema: application/jsonrequired
| controls | object Advanced generation controls (style, color, and artistic settings). |
| prompt required | string Text prompt describing what to generate. |
| size | string Output dimensions (width × height). |
| style | string Visual style preset to apply. |
| substyle | string A finer style variant within the chosen style. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with recraftv4-1-utility via x402.
$0.072000 per call. Flat price, charged only on success.
Pay-per-call recraftv4-1-utility (text-to-image).
Request Body schema: application/jsonrequired
| controls | object Advanced generation controls (style, color, and artistic settings). |
| prompt required | string Text prompt describing what to generate. |
| size | string Output dimensions (width × height). |
| style | string Visual style preset to apply. |
| substyle | string A finer style variant within the chosen style. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with recraftv4-1 via x402.
$0.072000 per call. Flat price, charged only on success.
Pay-per-call recraftv4-1 (text-to-image).
Request Body schema: application/jsonrequired
| controls | object Advanced generation controls (style, color, and artistic settings). |
| prompt required | string Text prompt describing what to generate. |
| size | string Output dimensions (width × height). |
| style | string Visual style preset to apply. |
| substyle | string A finer style variant within the chosen style. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with recraftv4-1-pro via x402.
$0.450000 per call. Flat price, charged only on success.
Pay-per-call recraftv4-1-pro (text-to-image).
Request Body schema: application/jsonrequired
| controls | object Advanced generation controls (style, color, and artistic settings). |
| prompt required | string Text prompt describing what to generate. |
| size | string Output dimensions (width × height). |
| style | string Visual style preset to apply. |
| substyle | string A finer style variant within the chosen style. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with recraftv4 via x402.
$0.072000 per call. Flat price, charged only on success.
Pay-per-call recraftv4 (text-to-image).
Request Body schema: application/jsonrequired
| controls | object Advanced generation controls (style, color, and artistic settings). |
| prompt required | string Text prompt describing what to generate. |
| size | string Output dimensions (width × height). |
| style | string Visual style preset to apply. |
| substyle | string A finer style variant within the chosen style. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with recraftv3 via x402.
$0.072000 per call. Flat price, charged only on success.
Pay-per-call recraftv3 (text-to-image).
Request Body schema: application/jsonrequired
| controls | object Advanced generation controls (style, color, and artistic settings). |
| prompt required | string Text prompt describing what to generate. |
| size | string Output dimensions (width × height). |
| style | string Visual style preset to apply. |
| substyle | string A finer style variant within the chosen style. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with gpt-image-2 via x402.
$0.048000 per call. Flat price, charged only on success.
Pay-per-call gpt-image-2 (text-to-image).
Request Body schema: application/jsonrequired
| background | string Enum: "opaque" "auto" Background transparency setting. Use transparent for images with no background, opaque for a solid background, or auto to let the model decide. |
| images | Array of strings <uri> [ items <uri > ] Input images for image editing, 1-16 entries. Each entry is base64-encoded (raw string or data:image/{png|jpeg|webp};base64,... URI). Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| output_format | string Enum: "png" "webp" "jpeg" Output format for the generated image |
| prompt required | string Text prompt describing the image to generate or edit |
| quality | string Enum: "low" "medium" "high" "auto" Quality of the generated image |
| size | string Enum: "1024x1024" "1024x1536" "1536x1024" "auto" Size of the generated image |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with gpt-image-1.5 via x402.
$0.048000 per call. Flat price, charged only on success.
Pay-per-call gpt-image-1.5 (text-to-image).
Request Body schema: application/jsonrequired
| images | Array of strings <uri> [ items <uri > ] Input images for image editing, 1-16 entries. Each entry is base64-encoded (raw string or data:image/{png|jpeg|webp};base64,... URI). Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| prompt required | string Text prompt describing the image to generate or edit |
| quality | string Enum: "low" "medium" "high" "auto" Quality of the generated image |
| size | string Enum: "256x256" "512x512" "1024x1024" "1792x1024" "1024x1792" Size of the generated image |
| style | string Enum: "vivid" "natural" Style of the generated image |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with nano-banana-pro via x402.
$0.186000 per call. Flat price, charged only on success.
Pay-per-call nano-banana-pro (text-to-image).
Request Body schema: application/jsonrequired
| aspect_ratio | string Enum: "1:1" "3:2" "2:3" "3:4" "4:3" "4:5" "5:4" "9:16" "16:9" "21:9" Output aspect ratio (e.g. 16:9, 1:1, 9:16). |
| image_input | Array of strings <uri> [ items <uri > ] Reference image(s) to guide generation (HTTPS URL or upload). Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| image_size | string Enum: "1K" "2K" "4K" Output image dimensions. |
| output_format | string Enum: "jpg" "png" "webp" File format of the output (e.g. png, jpeg, mp4). |
| prompt required | string Text prompt describing what to generate. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with nano-banana via x402.
$0.046800 per call. Flat price, charged only on success.
Pay-per-call nano-banana (text-to-image).
Request Body schema: application/jsonrequired
| aspect_ratio | string Enum: "1:1" "3:2" "2:3" "3:4" "4:3" "4:5" "5:4" "9:16" "16:9" "21:9" Output aspect ratio (e.g. 16:9, 1:1, 9:16). |
| image_input | Array of strings <uri> [ items <uri > ] Reference image(s) to guide generation (HTTPS URL or upload). Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| image_size | string Enum: "1K" "2K" "4K" Output image dimensions. |
| output_format | string Enum: "jpg" "png" "webp" File format of the output (e.g. png, jpeg, mp4). |
| prompt required | string Text prompt describing what to generate. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with brainrot-character via x402.
$0.200000 per call. Flat price, charged only on success.
Pay-per-call brainrot-character (text-to-image).
Request Body schema: application/jsonrequired
| reference_image | string Optional reference image — the character is built FROM it (brainrot-ified). Pass a public URL, or upload a local file (free) via POST /v1/media (≤40MB) and pass the returned url. Omit for a hyper-random ORIGINAL character. |
| seed | integer Optional seed to reproduce the same random original; omit for a new one each call. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{ }Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with nano-banana-2 via x402.
$0.114000 per call. Flat price, charged only on success.
Pay-per-call nano-banana-2 (text-to-image).
Request Body schema: application/jsonrequired
| aspect_ratio | string Enum: "match_input_image" "1:1" "2:3" "3:2" "3:4" "4:3" "4:5" "5:4" "9:16" "16:9" "21:9" Output aspect ratio (e.g. 16:9, 1:1, 9:16). |
| google_search | boolean Allow the model to use Google Search for grounding. |
| image_input | Array of strings <uri> [ items <uri > ] Reference image(s) to guide generation (HTTPS URL or upload). Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| image_search | boolean Allow the model to search for reference images. |
| output_format | string Enum: "jpg" "png" File format of the output (e.g. png, jpeg, mp4). |
| prompt required | string Text prompt describing what to generate. |
| resolution | string Enum: "1K" "2K" "4K" Output resolution / quality tier. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with imagen-4 via x402.
$0.072000 per call. Flat price, charged only on success.
Pay-per-call imagen-4 (text-to-image).
Request Body schema: application/jsonrequired
| aspect_ratio | string Enum: "1:1" "3:4" "4:3" "9:16" "16:9" Aspect ratio of the generated image |
| person_generation | string Enum: "dont_allow" "allow_adult" "allow_all" Allow the model to generate images of people. dont_allow: block people, allow_adult: adults only, allow_all: adults and children |
| prompt required | string Text prompt describing the image to generate |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with seedream-4.5 via x402.
$0.072000 per call. Flat price, charged only on success.
Pay-per-call seedream-4.5 (text-to-image).
Request Body schema: application/jsonrequired
| aspect_ratio | string Enum: "match_input_image" "1:1" "4:3" "3:4" "16:9" "9:16" "3:2" "2:3" "21:9" Output aspect ratio (e.g. 16:9, 1:1, 9:16). |
| disable_safety_checker | boolean Turn off the safety filter on outputs. |
| image_input | Array of strings <uri> [ items <uri > ] Reference image(s) to guide generation (HTTPS URL or upload). Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| max_images | integer [ 1 .. 15 ] Maximum number of images to return. |
| prompt required | string Text prompt describing what to generate. |
| sequential_image_generation | string Enum: "disabled" "auto" Generate a sequence of related images. |
| size | string Enum: "2K" "4K" Output dimensions (width × height). |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with seedream-5-lite via x402.
$0.063000 per call. Flat price, charged only on success.
Pay-per-call seedream-5-lite (text-to-image).
Request Body schema: application/jsonrequired
| aspect_ratio | string Enum: "match_input_image" "1:1" "4:3" "3:4" "16:9" "9:16" "3:2" "2:3" "21:9" Output aspect ratio (e.g. 16:9, 1:1, 9:16). |
| image_input | Array of strings <uri> [ items <uri > ] Reference image(s) to guide generation (HTTPS URL or upload). Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| max_images | integer [ 1 .. 15 ] Maximum number of images to return. |
| output_format | string Enum: "png" "jpeg" File format of the output (e.g. png, jpeg, mp4). |
| prompt required | string Text prompt describing what to generate. |
| sequential_image_generation | string Enum: "disabled" "auto" Generate a sequence of related images. |
| size | string Enum: "2K" "3K" Output dimensions (width × height). |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with seedream-4.0 via x402.
$0.054000 per call. Flat price, charged only on success.
Pay-per-call seedream-4.0 (text-to-image).
Request Body schema: application/jsonrequired
| aspect_ratio | string Enum: "match_input_image" "1:1" "4:3" "3:4" "16:9" "9:16" "3:2" "2:3" "21:9" Output aspect ratio (e.g. 16:9, 1:1, 9:16). |
| enhance_prompt | boolean Let the model automatically expand/improve your prompt. |
| height | integer [ 1024 .. 4096 ] Output height in pixels. |
| prompt required | string Text prompt describing what to generate. |
| size | string Enum: "1K" "2K" "4K" "custom" Output dimensions (width × height). |
| width | integer [ 1024 .. 4096 ] Output width in pixels. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with wan-2.6-image via x402.
$0.054000 per call. Flat price, charged only on success.
Pay-per-call wan-2.6-image (text-to-image).
Request Body schema: application/jsonrequired
| negative_prompt | string What to avoid in the output. |
| prompt required | string Text prompt describing what to generate. |
| size | string Output dimensions (width × height). |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with krea-2-medium-turbo via x402.
$0.018000 per call. Flat price, charged only on success.
Pay-per-call krea-2-medium-turbo (text-to-image).
Request Body schema: application/jsonrequired
| aspect_ratio | string Enum: "1:1" "4:3" "3:2" "16:9" "2.35:1" "4:5" "2:3" "9:16" Aspect ratio of the generated image. |
| complexity | integer [ -100 .. 100 ] K2 Complexity slider (-100 to 100). 0 disables the slider LoRA. |
| creativity | string Enum: "raw" "low" "medium" "high" Prompt expansion mode. |
| image_style_references | Array of strings <uri> [ items <uri > ] Reference images to drive the visual style (up to 10). Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| intensity | integer [ -100 .. 100 ] K2 Intensity slider (-100 to 100). 0 disables the slider LoRA. |
| moodboards | Array of arrays Moodboard references (currently limited to one). |
| movement | integer [ -100 .. 100 ] K2 Movement slider (-100 to 100). 0 disables the slider LoRA. |
| prompt required | string Text prompt describing the image to generate. |
| resolution | string Value: "1K" Resolution scale. |
| seed | any Random seed for reproducible generations. Pass null or omit for a random seed. |
| styles | Array of arrays Styles (typically LoRAs) to apply to the generation. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with krea-2-medium via x402.
$0.036000 per call. Flat price, charged only on success.
Pay-per-call krea-2-medium (text-to-image).
Request Body schema: application/jsonrequired
| aspect_ratio | string Enum: "1:1" "4:3" "3:2" "16:9" "2.35:1" "4:5" "2:3" "9:16" Aspect ratio of the generated image. |
| complexity | integer [ -100 .. 100 ] K2 Complexity slider (-100 to 100). 0 disables the slider LoRA. |
| creativity | string Enum: "raw" "low" "medium" "high" Prompt expansion mode. |
| image_style_references | Array of strings <uri> [ items <uri > ] Reference images to drive the visual style (up to 10). Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| intensity | integer [ -100 .. 100 ] K2 Intensity slider (-100 to 100). 0 disables the slider LoRA. |
| moodboards | Array of arrays Moodboard references (currently limited to one). |
| movement | integer [ -100 .. 100 ] K2 Movement slider (-100 to 100). 0 disables the slider LoRA. |
| prompt required | string Text prompt describing the image to generate. |
| resolution | string Value: "1K" Resolution scale. |
| seed | any Random seed for reproducible generations. Pass null or omit for a random seed. |
| styles | Array of arrays Styles (typically LoRAs) to apply to the generation. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with krea-2-large via x402.
$0.072000 per call. Flat price, charged only on success.
Pay-per-call krea-2-large (text-to-image).
Request Body schema: application/jsonrequired
| aspect_ratio | string Enum: "1:1" "4:3" "3:2" "16:9" "2.35:1" "4:5" "2:3" "9:16" Aspect ratio of the generated image. |
| complexity | integer [ -100 .. 100 ] K2 Complexity slider (-100 to 100). 0 disables the slider LoRA. |
| creativity | string Enum: "raw" "low" "medium" "high" Prompt expansion mode. |
| image_style_references | Array of strings <uri> [ items <uri > ] Reference images to drive the visual style (up to 10). Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| intensity | integer [ -100 .. 100 ] K2 Intensity slider (-100 to 100). 0 disables the slider LoRA. |
| moodboards | Array of arrays Moodboard references (currently limited to one). |
| movement | integer [ -100 .. 100 ] K2 Movement slider (-100 to 100). 0 disables the slider LoRA. |
| prompt required | string Text prompt describing the image to generate. |
| resolution | string Value: "1K" Resolution scale. |
| seed | any Random seed for reproducible generations. Pass null or omit for a random seed. |
| styles | Array of arrays Styles (typically LoRAs) to apply to the generation. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with seedream-5-pro via x402.
$0.054000 per call. Flat price, charged only on success.
Pay-per-call seedream-5-pro (text-to-image).
Request Body schema: application/jsonrequired
| prompt required | string Text prompt describing what to generate. |
| image | any Input image (HTTPS URL or upload) to guide or edit from. |
| size | string Output dimensions (width × height). |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image with nano-banana-2-lite via x402.
$0.046440 per call. Flat price, charged only on success.
Pay-per-call nano-banana-2-lite (text-to-image).
Request Body schema: application/jsonrequired
| prompt required | string Text prompt describing what to generate. |
| image_input | Array of strings <uri> [ items <uri > ] Reference image(s) to guide generation (HTTPS URL or upload). Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| aspect_ratio | string Enum: "match_input_image" "1:1" "2:3" "3:2" "3:4" "4:3" "4:5" "5:4" "9:16" "16:9" "21:9" Output aspect ratio (e.g. 16:9, 1:1, 9:16). |
| output_format | string Enum: "jpg" "png" File format of the output (e.g. png, jpeg, mp4). |
| resolution | string Enum: "1K" "2K" "4K" Output resolution / quality tier. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Run any of 90+ generative models pay-per-call.
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
One endpoint for the whole catalog: send { model, ...modelInput } — pick any model from GET /v1/models (90+ across image, video, image-to-video, text-to-speech, speech-to-text, music). Responds 402 Payment Required with the per-model price; pay from your own account and retry.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id (see GET /v1/models). |
| prompt | string Most models take a text prompt; STT/some take a file/url instead. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "grok-imagine-image",
- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Generate a video from a text prompt or an image.
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Capability endpoint — pick any matching model with GET /v1/models and pass it as { model }. Same pay-per-call charge as /v1/infer (402, then pay and retry); the per-model POST /x402/wan-2.7-i2v path also works.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id (see GET /v1/models). |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "wan-2.7-i2v",
- "prompt": "a timelapse of clouds over mountains"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Run any of 90+ models over a payment channel (pay-as-you-go).
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Open one Tempo channel and pay many calls with off-chain vouchers; settle on close. Non-custodial — the deposit stays in the on-chain escrow.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "string"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Generate a video with brainrot-video via x402.
$1.050000 per call. Flat price, charged only on success.
Pay-per-call brainrot-video (text-to-video).
Request Body schema: application/jsonrequired
| reference_image | string Optional reference image — the character is built FROM it (brainrot-ified), then animated. Pass a public URL, or upload a local file (free) via POST /v1/media (≤40MB). Omit for a hyper-random ORIGINAL character. |
| motionPrompt | string Optional description of how the character should move (default: chaotic dancing meme energy). |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{ }Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate a video with q3-pro via x402.
$0.217500–$3.480000 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call q3-pro (text-to-video). Priced per second ($0.217500/sec) — final price = video length x rate (duration 1-16s).
Request Body schema: application/jsonrequired
| aspect_ratio | string Enum: "16:9" "9:16" "3:4" "4:3" "1:1" Video aspect ratio (text-to-video only). Default: 16:9 |
| audio | boolean Enable audio-video synchronization. Default: true for Q3 models. When false, outputs silent video |
| duration | integer [ 1 .. 16 ] Video duration in seconds (1-16) |
| end_image | string End image for start/end-to-video generation. Must be used together with start_image. Accepts public URL or Base64 data URI (data:image/png;base64,...) Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| prompt | string Text prompt describing what should appear in the video |
| resolution | string Enum: "540p" "720p" "1080p" Video resolution |
| start_image | string Start image for video generation. Use alone for image-to-video, or with end_image for start/end-to-video. Accepts public URL or Base64 data URI (data:image/png;base64,...) Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate a video with q3-turbo via x402.
$0.101500–$1.624000 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call q3-turbo (text-to-video). Priced per second ($0.101500/sec) — final price = video length x rate (duration 1-16s).
Request Body schema: application/jsonrequired
| aspect_ratio | string Enum: "16:9" "9:16" "3:4" "4:3" "1:1" Video aspect ratio (text-to-video only). Default: 16:9 |
| audio | boolean Enable audio-video synchronization. Default: true for Q3 models. When false, outputs silent video |
| duration | integer [ 1 .. 16 ] Video duration in seconds (1-16) |
| end_image | string End image for start/end-to-video generation. Must be used together with start_image. Accepts public URL or Base64 data URI (data:image/png;base64,...) Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| prompt | string Text prompt describing what should appear in the video |
| resolution | string Enum: "540p" "720p" "1080p" Video resolution |
| start_image | string Start image for video generation. Use alone for image-to-video, or with end_image for start/end-to-video. Accepts public URL or Base64 data URI (data:image/png;base64,...) Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate a video with gen-4.5 via x402.
$0.522000–$2.610000 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call gen-4.5 (text-to-video). Priced per second ($0.261000/sec) — final price = video length x rate (duration 2-10s).
Request Body schema: application/jsonrequired
| content_moderation | object Content moderation settings |
| duration | integer [ 2 .. 10 ] Video duration in seconds |
| image_input | string HTTPS URL, Runway URI, or data URI containing an image for image-to-video Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| prompt required | string Text prompt describing what should appear in the video |
| ratio | string Enum: "1280:720" "720:1280" "1104:832" "960:960" "832:1104" "1584:672" Resolution/aspect ratio of the output video |
| seed | integer [ 0 .. 4294967295 ] Random seed for reproducible results |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate a video with v6 via x402.
$0.166750–$2.501250 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call v6 (text-to-video). Priced per second ($0.166750/sec) — final price = video length x rate (duration 1-15s).
Request Body schema: application/jsonrequired
| aspect_ratio | string Enum: "16:9" "4:3" "1:1" "3:4" "9:16" "2:3" "3:2" "21:9" Video aspect ratio |
| duration | integer [ 1 .. 15 ] Video duration in seconds (1 to 15) |
| generate_audio | boolean Whether to generate audio with the video |
| image_input | string Base64-encoded reference image for image-to-video generation (data:image/...;base64,...). The image will be uploaded to Pixverse automatically. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| negative_prompt | string Negative text prompt |
| prompt required | string Text prompt describing the video to generate |
| quality | string Enum: "360p" "540p" "720p" "1080p" Video quality |
| seed | integer [ 0 .. 2147483647 ] Random seed for reproducibility |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate a video with v5.6 via x402.
$0.217500–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call v5.6 (text-to-video). Priced per second ($0.217500/sec) — final price = video length x rate.
Request Body schema: application/jsonrequired
| aspect_ratio | string Enum: "16:9" "4:3" "1:1" "3:4" "9:16" "2:3" "3:2" "21:9" Video aspect ratio |
| duration | number Enum: 5 8 10 Video duration in seconds |
| generate_audio | boolean Whether to generate audio with the video |
| image_input | string Base64-encoded reference image for image-to-video generation (data:image/...;base64,...). The image will be uploaded to Pixverse automatically. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| motion_mode | string Enum: "normal" "fast" Motion mode (fast only available when duration=5; 1080p does not support fast) |
| negative_prompt | string Negative text prompt |
| prompt required | string Text prompt describing the video to generate |
| quality | string Enum: "360p" "540p" "720p" "1080p" Video quality |
| seed | integer [ 0 .. 2147483647 ] Random seed for reproducibility |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate a video with hailuo-2.3 via x402.
$0.118418–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call hailuo-2.3 (text-to-video). Priced per second ($0.118418/sec) — final price = video length x rate.
Request Body schema: application/jsonrequired
| duration | number Enum: 6 10 Length of the output in seconds. |
| fast_pretreatment | boolean Faster input pre-processing (may trade a little quality for speed). |
| first_frame_image | string Image to use as the first frame of the video. |
| prompt | string Text prompt describing what to generate. |
| prompt_optimizer | boolean Let the model automatically optimize your prompt. |
| resolution | string Enum: "768P" "1080P" Output resolution / quality tier. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate a video with veo-3.1-fast via x402.
$0.435000–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call veo-3.1-fast (text-to-video). Priced per second ($0.435000/sec) — final price = video length x rate.
Request Body schema: application/jsonrequired
| aspect_ratio | string Enum: "16:9" "9:16" "1:1" Video aspect ratio |
| duration | string Enum: "4s" "6s" "8s" Video duration |
| generate_audio | boolean Whether to generate audio with the video |
| image_input | string Base64-encoded reference image for i2v Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| prompt required | string Text prompt describing the video to generate |
| resolution | string Enum: "720p" "1080p" Video resolution |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate a video with veo-3.1 via x402.
$0.870000–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call veo-3.1 (text-to-video). Priced per second ($0.870000/sec) — final price = video length x rate.
Request Body schema: application/jsonrequired
| aspect_ratio | string Enum: "16:9" "9:16" "1:1" Video aspect ratio |
| duration | string Enum: "4s" "6s" "8s" Video duration |
| generate_audio | boolean Whether to generate audio with the video |
| image_input | string Base64-encoded reference image for i2v Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| prompt required | string Text prompt describing the video to generate |
| resolution | string Enum: "720p" "1080p" Video resolution |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate a video with seedance-2.0-fast via x402.
$0.986000–$2.958000 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call seedance-2.0-fast (text-to-video). Priced per second ($0.246500/sec) — final price = video length x rate (duration 4-12s).
Request Body schema: application/jsonrequired
| aspect_ratio | string Enum: "16:9" "4:3" "1:1" "3:4" "9:16" "21:9" "9:21" Video aspect ratio. Ignored if an image is used. |
| camera_fixed | boolean Whether to fix camera position |
| duration | integer [ 4 .. 12 ] Video duration in seconds |
| fps | number Frame rate (frames per second) |
| generate_audio | boolean Whether to generate audio with the video |
| image | string Reference image (HTTP(S) URL or base64 data URI) for image-to-video Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| last_frame_image | string Reference image (HTTP(S) URL or base64 data URI) for last-frame guidance. Only works if an image start frame is also given. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| prompt required | string Text prompt describing the video to generate |
| reference_images | Array of strings <uri> [ items <uri > ] Reference images (1-4, HTTP(S) URLs or base64 data URIs) to guide video generation for characters, avatars, clothing, or environments. Cannot be used with 1080p resolution or first/last frame images. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| reference_video | string Reference video (HTTP(S) URL or base64 data URI) for style/motion guidance Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| resolution | string Enum: "480p" "720p" Video resolution |
| seed | integer Random seed for reproducible generation |
| watermark | boolean Whether to add a watermark to the output video |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate a video with seedance-2.0-mini via x402.
$0.638000–$1.914000 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call seedance-2.0-mini (text-to-video). Priced per second ($0.159500/sec) — final price = video length x rate (duration 4-12s).
Request Body schema: application/jsonrequired
| prompt required | string Text prompt describing the video to generate |
| image | string Reference image (HTTP(S) URL or base64 data URI) for image-to-video Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| reference_video | string Reference video (HTTP(S) URL or base64 data URI) for style/motion guidance Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| last_frame_image | string Reference image (HTTP(S) URL or base64 data URI) for last-frame guidance. Only works if an image start frame is also given. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| reference_images | Array of strings <uri> [ items <uri > ] Reference images (1-4, HTTP(S) URLs or base64 data URIs) to guide video generation for characters, avatars, clothing, or environments. Cannot be used with 1080p resolution or first/last frame images. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| duration | integer [ 4 .. 12 ] Video duration in seconds |
| resolution | string Enum: "480p" "720p" Video resolution |
| aspect_ratio | string Enum: "16:9" "4:3" "1:1" "3:4" "9:16" "21:9" "9:21" Video aspect ratio. Ignored if an image is used. |
| fps | number Frame rate (frames per second) |
| camera_fixed | boolean Whether to fix camera position |
| generate_audio | boolean Whether to generate audio with the video |
| watermark | boolean Whether to add a watermark to the output video |
| seed | integer Random seed for reproducible generation |
| reference_audio | string Reference audio (HTTP(S) URL or base64 data:audio/... URI) to use as background music. Must be accompanied by a reference image or video. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate a video with seedance-2.0 via x402.
$3.190000–$9.570000 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call seedance-2.0 (text-to-video). Priced per second ($0.797500/sec) — final price = video length x rate (duration 4-12s).
Request Body schema: application/jsonrequired
| aspect_ratio | string Enum: "16:9" "4:3" "1:1" "3:4" "9:16" "21:9" "9:21" Video aspect ratio. Ignored if an image is used. |
| camera_fixed | boolean Whether to fix camera position |
| duration | integer [ 4 .. 12 ] Video duration in seconds |
| fps | number Frame rate (frames per second) |
| generate_audio | boolean Whether to generate audio with the video |
| image | string Reference image (HTTP(S) URL or base64 data URI) for image-to-video Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| last_frame_image | string Reference image (HTTP(S) URL or base64 data URI) for last-frame guidance. Only works if an image start frame is also given. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| prompt required | string Text prompt describing the video to generate |
| reference_images | Array of strings <uri> [ items <uri > ] Reference images (1-4, HTTP(S) URLs or base64 data URIs) to guide video generation for characters, avatars, clothing, or environments. Cannot be used with 1080p resolution or first/last frame images. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| reference_video | string Reference video (HTTP(S) URL or base64 data URI) for style/motion guidance Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| resolution | string Enum: "480p" "720p" "1080p" Video resolution |
| seed | integer Random seed for reproducible generation |
| watermark | boolean Whether to add a watermark to the output video |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate a video with hh1-t2v via x402.
$1.218000–$6.090000 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call hh1-t2v (text-to-video). Priced per second ($0.406000/sec) — final price = video length x rate (duration 3-15s).
Request Body schema: application/jsonrequired
| duration | integer [ 3 .. 15 ] Length of the output in seconds. |
| prompt required | string Text prompt describing what to generate. |
| ratio | string Enum: "16:9" "9:16" "1:1" "4:3" "3:4" Output aspect ratio. |
| resolution | string Enum: "720P" "1080P" Output resolution / quality tier. |
| seed | integer [ 0 .. 2147483647 ] Random seed for reproducible results — same seed + inputs gives the same output. |
| watermark | boolean Whether to add a watermark to the output. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate a video with hh1.1-t2v via x402.
$0.783000–$3.915000 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call hh1.1-t2v (text-to-video). Priced per second ($0.261000/sec) — final price = video length x rate (duration 3-15s).
Request Body schema: application/jsonrequired
| prompt required | string Text prompt describing what to generate. |
| resolution | string Enum: "720P" "1080P" Output resolution / quality tier. |
| ratio | string Enum: "16:9" "9:16" "1:1" "4:3" "3:4" Output aspect ratio. |
| duration | integer [ 3 .. 15 ] Length of the output in seconds. |
| seed | integer [ 0 .. 2147483647 ] Random seed for reproducible results — same seed + inputs gives the same output. |
| watermark | boolean Whether to add a watermark to the output. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Run any of 90+ generative models pay-per-call.
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
One endpoint for the whole catalog: send { model, ...modelInput } — pick any model from GET /v1/models (90+ across image, video, image-to-video, text-to-speech, speech-to-text, music). Responds 402 Payment Required with the per-model price; pay from your own account and retry.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id (see GET /v1/models). |
| prompt | string Most models take a text prompt; STT/some take a file/url instead. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "grok-imagine-image",
- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Convert text to speech with any TTS model.
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Capability endpoint — pick any matching model with GET /v1/models and pass it as { model }. Same pay-per-call charge as /v1/infer (402, then pay and retry); the per-model POST /x402/grok-tts path also works.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id (see GET /v1/models). |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "grok-tts",
- "input": "Hello from GlianaAI."
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Run any of 90+ models over a payment channel (pay-as-you-go).
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Open one Tempo channel and pay many calls with off-chain vouchers; settle on close. Non-custodial — the deposit stays in the on-chain escrow.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "string"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Convert text to speech with grok-tts via x402.
$0.001000–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call grok-tts (tts). Priced per character — final price scales with text length; min is the smallest possible charge.
Request Body schema: application/jsonrequired
| language | string BCP-47 language code (e.g. "en", "zh", "pt-BR") or "auto" for automatic language detection. Required for both REST and WebSocket modes. Supported codes: auto, en, ar-EG, ar-SA, ar-AE, bn, zh, fr, de, hi, id, it, ja, ko, pt-BR, pt-PT, ru, es-MX, es-ES, tr, vi. |
| optimize_streaming_latency | number Enum: 0 1 Latency optimization for streaming synthesis. 0 (default): no optimization, best audio quality. 1: reduced first-chunk size for lower time-to-first-audio with minor quality tradeoff. |
| output_format | object Output audio format. Defaults to MP3 at 24 kHz / 128 kbps when omitted. |
| speed | number [ 0.7 .. 1.5 ] Speech speed multiplier. 1.0 is normal speed. Range: 0.7 to 1.5. Defaults to 1.0. Only used in WebSocket mode. |
| text required | string Text to convert to speech. Maximum 15,000 characters. Supports inline speech tags: [pause], [laugh], |
| text_normalization | boolean When true, normalizes written-form text into spoken-form before synthesis (e.g. "Dr." → "Doctor", "100" → "one hundred"). Defaults to false. |
| voice_id | string Voice for synthesis. Defaults to "eve". Built-in voices: eve (energetic), ara (warm), rex (confident), sal (balanced), leo (authoritative). Custom voice IDs from /v1/tts/voices are also accepted. Case-insensitive — "Eve", "EVE", and "eve" are equivalent. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "text": "Hello from GlianaAI."
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Convert text to speech with tts-1-hd via x402.
$0.001000–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call tts-1-hd (tts). Priced per character — final price scales with text length; min is the smallest possible charge.
Request Body schema: application/jsonrequired
| response_format | string Enum: "mp3" "opus" "wav" "aac" "flac" The output format for the audio. Supported formats are mp3, opus, wav, aac and flac. |
| speed | number [ 0.25 .. 4 ] The speed of the generated audio. Select a value from 0.25 to 4.0. 1.0 is the default. |
| text required | string The text to generate audio for. Maximum length is 4096 characters. |
| voice | string Enum: "alloy" "echo" "fable" "onyx" "nova" "shimmer" The voice to use when generating the audio. Defaults to alloy. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "text": "Hello from GlianaAI."
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Convert text to speech with tts-1 via x402.
$0.001000–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call tts-1 (tts). Priced per character — final price scales with text length; min is the smallest possible charge.
Request Body schema: application/jsonrequired
| response_format | string Enum: "mp3" "opus" "wav" "aac" "flac" The output format for the audio. Supported formats are mp3, opus, wav, aac and flac. |
| speed | number [ 0.25 .. 4 ] The speed of the generated audio. Select a value from 0.25 to 4.0. 1.0 is the default. |
| text required | string The text to generate audio for. Maximum length is 4096 characters. |
| voice | string Enum: "alloy" "echo" "fable" "onyx" "nova" "shimmer" The voice to use when generating the audio. Defaults to alloy. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "text": "Hello from GlianaAI."
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Convert text to speech with speech-2.8-turbo via x402.
$0.001000–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call speech-2.8-turbo (tts). Priced per character — final price scales with text length; min is the smallest possible charge.
Request Body schema: application/jsonrequired
| emotion | string Enum: "happy" "sad" "angry" "fearful" "disgusted" "surprised" "calm" "fluent" Emotion control for synthesized speech |
| format | string Enum: "mp3" "flac" "wav" Output audio format |
| pitch | integer [ -12 .. 12 ] Pitch adjustment (-12 to 12) |
| sample_rate | number Enum: 8000 16000 22050 24000 32000 44100 Audio sample rate |
| speed | number [ 0.5 .. 2 ] Speech speed (0.5 to 2) |
| text required | string The text to convert to speech. Maximum 10,000 characters. |
| voice_id | string The voice ID to use for synthesis |
| volume | number [ 0 .. 10 ] Speech volume (0 to 10) |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "text": "Hello from GlianaAI."
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Convert text to speech with speech-2.8-hd via x402.
$0.001000–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call speech-2.8-hd (tts). Priced per character — final price scales with text length; min is the smallest possible charge.
Request Body schema: application/jsonrequired
| emotion | string Enum: "happy" "sad" "angry" "fearful" "disgusted" "surprised" "calm" "fluent" Emotion control for synthesized speech |
| format | string Enum: "mp3" "flac" "wav" Output audio format |
| pitch | integer [ -12 .. 12 ] Pitch adjustment (-12 to 12) |
| sample_rate | number Enum: 8000 16000 22050 24000 32000 44100 Audio sample rate |
| speed | number [ 0.5 .. 2 ] Speech speed (0.5 to 2) |
| text required | string The text to convert to speech. Maximum 10,000 characters. |
| voice_id | string The voice ID to use for synthesis |
| volume | number [ 0 .. 10 ] Speech volume (0 to 10) |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "text": "Hello from GlianaAI."
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Convert text to speech with tts-2 via x402.
$0.001000–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call tts-2 (tts). Priced per character — final price scales with text length; min is the smallest possible charge.
Request Body schema: application/jsonrequired
| apply_text_normalization | boolean When enabled, text normalization expands numbers, dates, times, and abbreviations before converting to speech. Turning this off may reduce latency. |
| bit_rate | integer Bits per second of the audio. Only for compressed audio formats (mp3, opus). The default is 128,000. |
| output_format | string Enum: "mp3" "opus" "wav" "flac" The output format for the audio. Supported formats are mp3, opus, wav, and flac. Defaults to mp3. |
| sample_rate | integer The synthesis sample rate in hertz. Accepts: 8000, 16000, 22050, 24000, 32000, 44100, 48000. The default is 48,000. |
| speaking_rate | number [ 0.5 .. 1.5 ] Speaking rate/speed, in the range [0.5, 1.5]. The default is 1.0. We recommend using values above 0.8 to ensure high quality. |
| temperature | number [ 0.01 .. 2 ] Determines the degree of randomness when sampling audio tokens. Defaults to 1.0. Accepts values between 0 (exclusive) and 2 (inclusive). Higher values = more expressive, lower values = more deterministic. |
| text required | string The text to be synthesized into speech. Maximum input of 2,000 characters. |
| timestamp_type | string Enum: "none" "word" "character" Controls timestamp metadata returned with the audio. "word" returns word-level timing, "character" returns character-level timing. Note: adds latency. Defaults to none. |
| voice_id | string Enum: "Loretta" "Darlene" "Marlene" "Hank" "Evelyn" "Celeste" "Pippa" "Tessa" "Liam" "Callum" "Hamish" "Abby" "Graham" "Rupert" "Mortimer" "Snik" "Anjali" "Saanvi" "Arjun" "Claire" "Oliver" "Simon" "Elliot" "James" "Serena" "Gareth" "Vinny" "Lauren" "Jessica" "Ethan" "Tyler" "Jason" "Chloe" "Veronica" "Victoria" "Miranda" "Sebastian" "Victor" "Malcolm" "Nate" "Brian" "Amina" "Kelsey" "Derek" "Evan" "Kayla" "Jake" "Grant" "Tristan" "Nadia" "Selene" "Marcus" "Riley" "Damon" "Cedric" "Mia" "Naomi" "Jonah" "Levi" "Avery" "Brandon" "Conrad" "Bianca" "Lucian" "Trevor" "Alex" "Ashley" "Craig" "Deborah" "Dennis" "Edward" "Elizabeth" "Hades" "Julia" "Pixie" "Mark" "Olivia" "Priya" "Ronald" "Sarah" "Shaun" "Theodore" "Timothy" "Wendy" "Dominus" "Hana" "Clive" "Carter" "Blake" "Luna" "Reed" "Duncan" "Felix" "Eleanor" "Sophie" The ID of the voice to use for synthesizing speech. Defaults to Dennis. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "text": "Hello from GlianaAI."
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Convert text to speech with tts-1.5-max via x402.
$0.001000–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call tts-1.5-max (tts). Priced per character — final price scales with text length; min is the smallest possible charge.
Request Body schema: application/jsonrequired
| apply_text_normalization | boolean When enabled, text normalization expands numbers, dates, times, and abbreviations before converting to speech. Turning this off may reduce latency. |
| bit_rate | integer Bits per second of the audio. Only for compressed audio formats (mp3, opus). The default is 128,000. |
| output_format | string Enum: "mp3" "opus" "wav" "flac" The output format for the audio. Supported formats are mp3, opus, wav, and flac. Defaults to mp3. |
| sample_rate | integer The synthesis sample rate in hertz. Accepts: 8000, 16000, 22050, 24000, 32000, 44100, 48000. The default is 48,000. |
| speaking_rate | number [ 0.5 .. 1.5 ] Speaking rate/speed, in the range [0.5, 1.5]. The default is 1.0. We recommend using values above 0.8 to ensure high quality. |
| temperature | number [ 0.01 .. 2 ] Determines the degree of randomness when sampling audio tokens. Defaults to 1.0. Accepts values between 0 (exclusive) and 2 (inclusive). Higher values = more expressive, lower values = more deterministic. |
| text required | string The text to be synthesized into speech. Maximum input of 2,000 characters. |
| timestamp_type | string Enum: "none" "word" "character" Controls timestamp metadata returned with the audio. "word" returns word-level timing, "character" returns character-level timing. Note: adds latency. Defaults to none. |
| voice_id | string Enum: "Loretta" "Darlene" "Marlene" "Hank" "Evelyn" "Celeste" "Pippa" "Tessa" "Liam" "Callum" "Hamish" "Abby" "Graham" "Rupert" "Mortimer" "Snik" "Anjali" "Saanvi" "Arjun" "Claire" "Oliver" "Simon" "Elliot" "James" "Serena" "Gareth" "Vinny" "Lauren" "Jessica" "Ethan" "Tyler" "Jason" "Chloe" "Veronica" "Victoria" "Miranda" "Sebastian" "Victor" "Malcolm" "Nate" "Brian" "Amina" "Kelsey" "Derek" "Evan" "Kayla" "Jake" "Grant" "Tristan" "Nadia" "Selene" "Marcus" "Riley" "Damon" "Cedric" "Mia" "Naomi" "Jonah" "Levi" "Avery" "Brandon" "Conrad" "Bianca" "Lucian" "Trevor" "Alex" "Ashley" "Craig" "Deborah" "Dennis" "Edward" "Elizabeth" "Hades" "Julia" "Pixie" "Mark" "Olivia" "Priya" "Ronald" "Sarah" "Shaun" "Theodore" "Timothy" "Wendy" "Dominus" "Hana" "Clive" "Carter" "Blake" "Luna" "Reed" "Duncan" "Felix" "Eleanor" "Sophie" The ID of the voice to use for synthesizing speech. Defaults to Dennis. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "text": "Hello from GlianaAI."
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Convert text to speech with tts-1.5-mini via x402.
$0.001000–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call tts-1.5-mini (tts). Priced per character — final price scales with text length; min is the smallest possible charge.
Request Body schema: application/jsonrequired
| apply_text_normalization | boolean When enabled, text normalization expands numbers, dates, times, and abbreviations before converting to speech. Turning this off may reduce latency. |
| bit_rate | integer Bits per second of the audio. Only for compressed audio formats (mp3, opus). The default is 128,000. |
| output_format | string Enum: "mp3" "opus" "wav" "flac" The output format for the audio. Supported formats are mp3, opus, wav, and flac. Defaults to mp3. |
| sample_rate | integer The synthesis sample rate in hertz. Accepts: 8000, 16000, 22050, 24000, 32000, 44100, 48000. The default is 48,000. |
| speaking_rate | number [ 0.5 .. 1.5 ] Speaking rate/speed, in the range [0.5, 1.5]. The default is 1.0. We recommend using values above 0.8 to ensure high quality. |
| temperature | number [ 0.01 .. 2 ] Determines the degree of randomness when sampling audio tokens. Defaults to 1.0. Accepts values between 0 (exclusive) and 2 (inclusive). Higher values = more expressive, lower values = more deterministic. |
| text required | string The text to be synthesized into speech. Maximum input of 2,000 characters. |
| timestamp_type | string Enum: "none" "word" "character" Controls timestamp metadata returned with the audio. "word" returns word-level timing, "character" returns character-level timing. Note: adds latency. Defaults to none. |
| voice_id | string Enum: "Loretta" "Darlene" "Marlene" "Hank" "Evelyn" "Celeste" "Pippa" "Tessa" "Liam" "Callum" "Hamish" "Abby" "Graham" "Rupert" "Mortimer" "Snik" "Anjali" "Saanvi" "Arjun" "Claire" "Oliver" "Simon" "Elliot" "James" "Serena" "Gareth" "Vinny" "Lauren" "Jessica" "Ethan" "Tyler" "Jason" "Chloe" "Veronica" "Victoria" "Miranda" "Sebastian" "Victor" "Malcolm" "Nate" "Brian" "Amina" "Kelsey" "Derek" "Evan" "Kayla" "Jake" "Grant" "Tristan" "Nadia" "Selene" "Marcus" "Riley" "Damon" "Cedric" "Mia" "Naomi" "Jonah" "Levi" "Avery" "Brandon" "Conrad" "Bianca" "Lucian" "Trevor" "Alex" "Ashley" "Craig" "Deborah" "Dennis" "Edward" "Elizabeth" "Hades" "Julia" "Pixie" "Mark" "Olivia" "Priya" "Ronald" "Sarah" "Shaun" "Theodore" "Timothy" "Wendy" "Dominus" "Hana" "Clive" "Carter" "Blake" "Luna" "Reed" "Duncan" "Felix" "Eleanor" "Sophie" The ID of the voice to use for synthesizing speech. Defaults to Dennis. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "text": "Hello from GlianaAI."
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Convert text to speech with gemini-3.1-flash-tts via x402.
$0.014400 per call. Flat price, charged only on success.
Pay-per-call gemini-3.1-flash-tts (tts).
Request Body schema: application/jsonrequired
| maxOutputTokens | integer >= 0 Maximum number of tokens to generate |
| stopSequences | Array of arrays Sequences where the model will stop generating further tokens |
| temperature | number [ 0 .. 2 ] Controls randomness in generation (0-2) |
| text required | string The text to convert to speech. Maximum 10,000 characters. |
| topK | integer >= 0 Only sample from the top K tokens. Smaller K = more focused, larger K = more diverse |
| topP | number [ 0 .. 1 ] Nucleus sampling threshold (0-1). Tokens with cumulative probability up to topP are considered |
| voice | string Enum: "Zephyr" "Puck" "Charon" "Kore" "Fenrir" "Leda" "Orus" "Aoede" "Callirrhoe" "Autonoe" "Enceladus" "Iapetus" "Umbriel" "Algieba" "Despina" "Erinome" "Algenib" "Rasalgethi" "Laomedeia" "Achernar" "Alnilam" "Schedar" "Gacrux" "Pulcherrima" "Achird" "Zubenelgenubi" "Vindemiatrix" "Sadachbia" "Sadaltager" "Sulafat" The voice to use for speech synthesis |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "text": "Hello from GlianaAI."
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Convert text to speech with eleven-v3 via x402.
$0.001000–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call eleven-v3 (tts). Priced per character — final price scales with text length; min is the smallest possible charge.
Request Body schema: application/jsonrequired
| text required | string The text to convert into speech. |
| voice_id | string The ElevenLabs voice ID to use for generation. |
| output_format | string Enum: "mp3_22050_32" "mp3_24000_48" "mp3_44100_128" "mp3_44100_192" "mp3_44100_32" "mp3_44100_64" "mp3_44100_96" "opus_48000_128" "opus_48000_192" "opus_48000_32" "opus_48000_64" "opus_48000_96" File format of the output (e.g. png, jpeg, mp4). |
| language_code | string ISO 639-1 language code to enforce. |
| voice_settings | object |
| seed | integer [ 0 .. 4294967295 ] Random seed for reproducible results — same seed + inputs gives the same output. |
| previous_text | string |
| next_text | string |
| apply_text_normalization | string Enum: "auto" "on" "off" |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "text": "Hello from GlianaAI."
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Convert text to speech with eleven-multilingual-v2 via x402.
$0.001000–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call eleven-multilingual-v2 (tts). Priced per character — final price scales with text length; min is the smallest possible charge.
Request Body schema: application/jsonrequired
| text required | string The text to convert into speech. |
| voice_id | string The ElevenLabs voice ID to use for generation. |
| output_format | string Enum: "mp3_22050_32" "mp3_24000_48" "mp3_44100_128" "mp3_44100_192" "mp3_44100_32" "mp3_44100_64" "mp3_44100_96" "opus_48000_128" "opus_48000_192" "opus_48000_32" "opus_48000_64" "opus_48000_96" File format of the output (e.g. png, jpeg, mp4). |
| language_code | string ISO 639-1 language code to enforce. |
| voice_settings | object |
| seed | integer [ 0 .. 4294967295 ] Random seed for reproducible results — same seed + inputs gives the same output. |
| previous_text | string |
| next_text | string |
| apply_text_normalization | string Enum: "auto" "on" "off" |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "text": "Hello from GlianaAI."
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Convert text to speech with eleven-turbo-v2-5 via x402.
$0.001000–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call eleven-turbo-v2-5 (tts). Priced per character — final price scales with text length; min is the smallest possible charge.
Request Body schema: application/jsonrequired
| text required | string The text to convert into speech. |
| voice_id | string The ElevenLabs voice ID to use for generation. |
| output_format | string Enum: "mp3_22050_32" "mp3_24000_48" "mp3_44100_128" "mp3_44100_192" "mp3_44100_32" "mp3_44100_64" "mp3_44100_96" "opus_48000_128" "opus_48000_192" "opus_48000_32" "opus_48000_64" "opus_48000_96" File format of the output (e.g. png, jpeg, mp4). |
| language_code | string ISO 639-1 language code to enforce. |
| voice_settings | object |
| seed | integer [ 0 .. 4294967295 ] Random seed for reproducible results — same seed + inputs gives the same output. |
| previous_text | string |
| next_text | string |
| apply_text_normalization | string Enum: "auto" "on" "off" |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "text": "Hello from GlianaAI."
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Convert text to speech with eleven-flash-v2-5 via x402.
$0.001000–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call eleven-flash-v2-5 (tts). Priced per character — final price scales with text length; min is the smallest possible charge.
Request Body schema: application/jsonrequired
| text required | string The text to convert into speech. |
| voice_id | string The ElevenLabs voice ID to use for generation. |
| output_format | string Enum: "mp3_22050_32" "mp3_24000_48" "mp3_44100_128" "mp3_44100_192" "mp3_44100_32" "mp3_44100_64" "mp3_44100_96" "opus_48000_128" "opus_48000_192" "opus_48000_32" "opus_48000_64" "opus_48000_96" File format of the output (e.g. png, jpeg, mp4). |
| language_code | string ISO 639-1 language code to enforce. |
| voice_settings | object |
| seed | integer [ 0 .. 4294967295 ] Random seed for reproducible results — same seed + inputs gives the same output. |
| previous_text | string |
| next_text | string |
| apply_text_normalization | string Enum: "auto" "on" "off" |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "text": "Hello from GlianaAI."
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Run any of 90+ generative models pay-per-call.
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
One endpoint for the whole catalog: send { model, ...modelInput } — pick any model from GET /v1/models (90+ across image, video, image-to-video, text-to-speech, speech-to-text, music). Responds 402 Payment Required with the per-model price; pay from your own account and retry.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id (see GET /v1/models). |
| prompt | string Most models take a text prompt; STT/some take a file/url instead. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "grok-imagine-image",
- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Generate a video from a text prompt or an image.
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Capability endpoint — pick any matching model with GET /v1/models and pass it as { model }. Same pay-per-call charge as /v1/infer (402, then pay and retry); the per-model POST /x402/wan-2.7-i2v path also works.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id (see GET /v1/models). |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "wan-2.7-i2v",
- "prompt": "a timelapse of clouds over mountains"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Run any of 90+ models over a payment channel (pay-as-you-go).
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Open one Tempo channel and pay many calls with off-chain vouchers; settle on close. Non-custodial — the deposit stays in the on-chain escrow.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "string"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Generate a video with aleph-2 via x402.
$0.001000–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call aleph-2 (video-to-video). Priced per second ($0.487200/sec) — final price = video length x rate.
Request Body schema: application/jsonrequired
| content_moderation | object Settings that affect the behavior of the content moderation system |
| duration | number >= 0 Duration of the source video in seconds. Used for billing only — not sent to RunwayML. Provide this so the gateway can compute per-second video cost accurately. |
| keyframes | Array of strings <uri> [ items <uri > ] Timed guidance images placed at specific points in the input video. Each entry has a uri and either seconds (absolute timestamp) or at (fractional position). Up to 5. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| prompt required | string Text prompt describing the edit to apply to the input video |
| prompt_images | Array of strings <uri> [ items <uri > ] Image keyframes for guiding the edit at specific points in the output video. Up to 5. Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| seed | integer [ 0 .. 4294967295 ] Random seed for reproducible results |
| video_uri required | string HTTPS URL, Runway URI, or data URI of the source video to edit (≤30 seconds) Pass a public URL; to use a local file, upload it (free) via POST /v1/media (≤40MB) and pass the returned url. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table",
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Run any of 90+ generative models pay-per-call.
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
One endpoint for the whole catalog: send { model, ...modelInput } — pick any model from GET /v1/models (90+ across image, video, image-to-video, text-to-speech, speech-to-text, music). Responds 402 Payment Required with the per-model price; pay from your own account and retry.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id (see GET /v1/models). |
| prompt | string Most models take a text prompt; STT/some take a file/url instead. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "grok-imagine-image",
- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Generate chat completions with any LLM pay-per-call.
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Drop-in for the OpenAI chat completions API: swap the base URL, keep your SDK. Pick any text model from GET /v1/models (category "text"). Billing is a pre-charged ceiling — (estimated input tokens + max_tokens) at the model’s per-1M rates — so set max_tokens to bound spend; the response returns real usage. Supports messages (required), max_tokens, temperature, top_p, stream: true (SSE, OpenAI chunk format), tools/tool_choice (OpenAI function calling — tool_calls + role:"tool" round-trip), and vision (content parts with image_url on vision-capable models). 402 → pay → retry. FILE INPUT: if the image is already on the web or your own storage, pass image_url — we fetch it server-side at datacenter speed, which is the fastest option by far. Sending it inline as image_base64 is simplest and stores nothing anywhere, but base64 adds ~33% to the bytes and you pay your own upload speed, so it is best under ~1MB. For a large local file, upload the RAW bytes to POST /v1/media (free, ≤40MB) and pass the URL: same transfer as base64 minus the 33%, and identity endpoints delete the object as soon as they have read it.
Request Body schema: application/jsonrequired
| model required | string Text model id (see GET /v1/models, category "text"). |
required | Array of objects OpenAI-style chat messages: [{ role: "user"|"assistant"|"system"|"tool", content }]. |
| max_tokens | integer Output cap — bounds the pre-charged ceiling. Default 1024. |
Array of objects OpenAI function tools; response returns tool_calls. | |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "grok-4.3",
- "messages": [
- {
- "role": "user",
- "content": "Summarize x402 in one sentence."
}
], - "max_tokens": 256
}Run any of 90+ models over a payment channel (pay-as-you-go).
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Open one Tempo channel and pay many calls with off-chain vouchers; settle on close. Non-custodial — the deposit stays in the on-chain escrow.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "string"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Generate text with claude-fable-5 via x402.
$0.053771 per call. Flat price, charged only on success.
Pay-per-call claude-fable-5 (text).
Request Body schema: application/jsonrequired
| messages required | Array of arrays OpenAI-style chat messages: [{ role: "user" | "system" | "assistant" | "tool", content }]. Vision: content may be a parts array with { type: "image_url", image_url: { url } } (public URL — upload via POST /v1/media). |
| max_tokens | integer Output-token cap — bounds the pre-charged price ceiling. Default 1024. |
| temperature | number Sampling temperature. Passed through where the provider supports it. |
| top_p | number Nucleus sampling. Passed through where the provider supports it. |
| stream | boolean true → Server-Sent Events in the OpenAI chunk format (on /v1/chat/completions). |
| tools | Array of arrays OpenAI-style function tools: [{ type: "function", function: { name, description, parameters } }]. The response returns tool_calls (finish_reason "tool_calls"); send results back as { role: "tool", tool_call_id, content }. |
| tool_choice | string "auto" (default) | "none" | "required" | { type: "function", function: { name } }. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "messages": [
- {
- "role": "user",
- "content": "Summarize x402 in one sentence."
}
]
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate text with claude-opus-4.8 via x402.
$0.026886 per call. Flat price, charged only on success.
Pay-per-call claude-opus-4.8 (text).
Request Body schema: application/jsonrequired
| messages required | Array of arrays OpenAI-style chat messages: [{ role: "user" | "system" | "assistant" | "tool", content }]. Vision: content may be a parts array with { type: "image_url", image_url: { url } } (public URL — upload via POST /v1/media). |
| max_tokens | integer Output-token cap — bounds the pre-charged price ceiling. Default 1024. |
| temperature | number Sampling temperature. Passed through where the provider supports it. |
| top_p | number Nucleus sampling. Passed through where the provider supports it. |
| stream | boolean true → Server-Sent Events in the OpenAI chunk format (on /v1/chat/completions). |
| tools | Array of arrays OpenAI-style function tools: [{ type: "function", function: { name, description, parameters } }]. The response returns tool_calls (finish_reason "tool_calls"); send results back as { role: "tool", tool_call_id, content }. |
| tool_choice | string "auto" (default) | "none" | "required" | { type: "function", function: { name } }. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "messages": [
- {
- "role": "user",
- "content": "Summarize x402 in one sentence."
}
]
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate text with gpt-5.5-pro via x402.
$0.193568 per call. Flat price, charged only on success.
Pay-per-call gpt-5.5-pro (text).
Request Body schema: application/jsonrequired
| messages required | Array of arrays OpenAI-style chat messages: [{ role: "user" | "system" | "assistant" | "tool", content }]. Vision: content may be a parts array with { type: "image_url", image_url: { url } } (public URL — upload via POST /v1/media). |
| max_tokens | integer Output-token cap — bounds the pre-charged price ceiling. Default 1024. |
| temperature | number Sampling temperature. Passed through where the provider supports it. |
| top_p | number Nucleus sampling. Passed through where the provider supports it. |
| stream | boolean true → Server-Sent Events in the OpenAI chunk format (on /v1/chat/completions). |
| tools | Array of arrays OpenAI-style function tools: [{ type: "function", function: { name, description, parameters } }]. The response returns tool_calls (finish_reason "tool_calls"); send results back as { role: "tool", tool_call_id, content }. |
| tool_choice | string "auto" (default) | "none" | "required" | { type: "function", function: { name } }. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "messages": [
- {
- "role": "user",
- "content": "Summarize x402 in one sentence."
}
]
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate text with gpt-5.5 via x402.
$0.032262 per call. Flat price, charged only on success.
Pay-per-call gpt-5.5 (text).
Request Body schema: application/jsonrequired
| messages required | Array of arrays OpenAI-style chat messages: [{ role: "user" | "system" | "assistant" | "tool", content }]. Vision: content may be a parts array with { type: "image_url", image_url: { url } } (public URL — upload via POST /v1/media). |
| max_tokens | integer Output-token cap — bounds the pre-charged price ceiling. Default 1024. |
| temperature | number Sampling temperature. Passed through where the provider supports it. |
| top_p | number Nucleus sampling. Passed through where the provider supports it. |
| stream | boolean true → Server-Sent Events in the OpenAI chunk format (on /v1/chat/completions). |
| tools | Array of arrays OpenAI-style function tools: [{ type: "function", function: { name, description, parameters } }]. The response returns tool_calls (finish_reason "tool_calls"); send results back as { role: "tool", tool_call_id, content }. |
| tool_choice | string "auto" (default) | "none" | "required" | { type: "function", function: { name } }. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "messages": [
- {
- "role": "user",
- "content": "Summarize x402 in one sentence."
}
]
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate text with gemini-3.1-pro via x402.
$0.012905 per call. Flat price, charged only on success.
Pay-per-call gemini-3.1-pro (text).
Request Body schema: application/jsonrequired
| messages required | Array of arrays OpenAI-style chat messages: [{ role: "user" | "system" | "assistant" | "tool", content }]. Vision: content may be a parts array with { type: "image_url", image_url: { url } } (public URL — upload via POST /v1/media). |
| max_tokens | integer Output-token cap — bounds the pre-charged price ceiling. Default 1024. |
| temperature | number Sampling temperature. Passed through where the provider supports it. |
| top_p | number Nucleus sampling. Passed through where the provider supports it. |
| stream | boolean true → Server-Sent Events in the OpenAI chunk format (on /v1/chat/completions). |
| tools | Array of arrays OpenAI-style function tools: [{ type: "function", function: { name, description, parameters } }]. The response returns tool_calls (finish_reason "tool_calls"); send results back as { role: "tool", tool_call_id, content }. |
| tool_choice | string "auto" (default) | "none" | "required" | { type: "function", function: { name } }. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "messages": [
- {
- "role": "user",
- "content": "Summarize x402 in one sentence."
}
]
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate text with grok-4.3 via x402.
$0.002690 per call. Flat price, charged only on success.
Pay-per-call grok-4.3 (text).
Request Body schema: application/jsonrequired
| messages required | Array of arrays OpenAI-style chat messages: [{ role: "user" | "system" | "assistant" | "tool", content }]. Vision: content may be a parts array with { type: "image_url", image_url: { url } } (public URL — upload via POST /v1/media). |
| max_tokens | integer Output-token cap — bounds the pre-charged price ceiling. Default 1024. |
| temperature | number Sampling temperature. Passed through where the provider supports it. |
| top_p | number Nucleus sampling. Passed through where the provider supports it. |
| stream | boolean true → Server-Sent Events in the OpenAI chunk format (on /v1/chat/completions). |
| tools | Array of arrays OpenAI-style function tools: [{ type: "function", function: { name, description, parameters } }]. The response returns tool_calls (finish_reason "tool_calls"); send results back as { role: "tool", tool_call_id, content }. |
| tool_choice | string "auto" (default) | "none" | "required" | { type: "function", function: { name } }. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "messages": [
- {
- "role": "user",
- "content": "Summarize x402 in one sentence."
}
]
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate text with minimax-m3 via x402.
$0.001291 per call. Flat price, charged only on success.
Pay-per-call minimax-m3 (text).
Request Body schema: application/jsonrequired
| messages required | Array of arrays OpenAI-style chat messages: [{ role: "user" | "system" | "assistant" | "tool", content }]. Vision: content may be a parts array with { type: "image_url", image_url: { url } } (public URL — upload via POST /v1/media). |
| max_tokens | integer Output-token cap — bounds the pre-charged price ceiling. Default 1024. |
| temperature | number Sampling temperature. Passed through where the provider supports it. |
| top_p | number Nucleus sampling. Passed through where the provider supports it. |
| stream | boolean true → Server-Sent Events in the OpenAI chunk format (on /v1/chat/completions). |
| tools | Array of arrays OpenAI-style function tools: [{ type: "function", function: { name, description, parameters } }]. The response returns tool_calls (finish_reason "tool_calls"); send results back as { role: "tool", tool_call_id, content }. |
| tool_choice | string "auto" (default) | "none" | "required" | { type: "function", function: { name } }. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "messages": [
- {
- "role": "user",
- "content": "Summarize x402 in one sentence."
}
]
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate text with deepseek-v4-pro via x402.
$0.003744 per call. Flat price, charged only on success.
Pay-per-call deepseek-v4-pro (text).
Request Body schema: application/jsonrequired
| messages required | Array of arrays OpenAI-style chat messages: [{ role: "user" | "system" | "assistant" | "tool", content }]. Vision: content may be a parts array with { type: "image_url", image_url: { url } } (public URL — upload via POST /v1/media). |
| max_tokens | integer Output-token cap — bounds the pre-charged price ceiling. Default 1024. |
| temperature | number Sampling temperature. Passed through where the provider supports it. |
| top_p | number Nucleus sampling. Passed through where the provider supports it. |
| stream | boolean true → Server-Sent Events in the OpenAI chunk format (on /v1/chat/completions). |
| tools | Array of arrays OpenAI-style function tools: [{ type: "function", function: { name, description, parameters } }]. The response returns tool_calls (finish_reason "tool_calls"); send results back as { role: "tool", tool_call_id, content }. |
| tool_choice | string "auto" (default) | "none" | "required" | { type: "function", function: { name } }. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "messages": [
- {
- "role": "user",
- "content": "Summarize x402 in one sentence."
}
]
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate text with inkling via x402.
$0.005034 per call. Flat price, charged only on success.
Pay-per-call inkling (text).
Request Body schema: application/jsonrequired
| messages required | Array of arrays Conversation so far, OpenAI-style: [{ role: "user", content: "..." }]. Roles are system, user and assistant. Send the whole history each call — the API is stateless. |
| max_tokens required | number >= 0 Maximum tokens to generate. Billed at this ceiling rather than at actual usage, so ask for what you need — an unused allowance is still paid for. |
| system | string |
| temperature | number [ 0 .. 1 ] |
| top_p | number [ 0 .. 1 ] |
| top_k | number >= 0 |
| stream | boolean |
| metadata | object |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "messages": [
- {
- "role": "user",
- "content": "Summarize x402 in one sentence."
}
], - "max_tokens": 0
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate text with inkling-256k via x402.
$0.010068 per call. Flat price, charged only on success.
Pay-per-call inkling-256k (text).
Request Body schema: application/jsonrequired
| messages required | Array of arrays Conversation so far, OpenAI-style: [{ role: "user", content: "..." }]. Roles are system, user and assistant. Send the whole history each call — the API is stateless. |
| max_tokens required | number >= 0 Maximum tokens to generate. Billed at this ceiling rather than at actual usage, so ask for what you need — an unused allowance is still paid for. |
| system | string |
| temperature | number [ 0 .. 1 ] |
| top_p | number [ 0 .. 1 ] |
| top_k | number >= 0 |
| stream | boolean |
| metadata | object |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "messages": [
- {
- "role": "user",
- "content": "Summarize x402 in one sentence."
}
], - "max_tokens": 0
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate text with gemini-3.6-flash via x402.
$0.008066 per call. Flat price, charged only on success.
Pay-per-call gemini-3.6-flash (text).
Request Body schema: application/jsonrequired
| prompt | string Text prompt, or the model-specific input — see GET /v1/schema?model=. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate text with gemini-3.5-flash-lite via x402.
$0.002689 per call. Flat price, charged only on success.
Pay-per-call gemini-3.5-flash-lite (text).
Request Body schema: application/jsonrequired
| prompt | string Text prompt, or the model-specific input — see GET /v1/schema?model=. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a red apple on a table"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate text with grok-4.5 via x402.
$0.006454 per call. Flat price, charged only on success.
Pay-per-call grok-4.5 (text).
Request Body schema: application/jsonrequired
| messages required | Array of arrays Conversation so far, OpenAI-style: [{ role: "user", content: "..." }]. Roles are system, user and assistant. Send the whole history each call — the API is stateless. |
| max_completion_tokens | any |
| max_tokens | any |
| n | any How many outputs to generate. |
| parallel_tool_calls | any |
| prompt_cache_key | any |
| reasoning_effort | any |
| response_format | any How the result is returned (e.g. a URL or base64 data). |
| search_parameters | object |
| seed | any Random seed for reproducible results — same seed + inputs gives the same output. |
| service_tier | string Enum: "default" "priority" |
| stream | any |
| stream_options | object |
| temperature | any |
| tool_choice | any |
| tools | any |
| top_p | any |
| user | any Optional end-user identifier for abuse monitoring; not required. |
| web_search_options | object |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "messages": [
- {
- "role": "user",
- "content": "Summarize x402 in one sentence."
}
]
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate text with gpt-5.6-luna via x402.
$0.006453 per call. Flat price, charged only on success.
Pay-per-call gpt-5.6-luna (text).
Request Body schema: application/jsonrequired
| input required | any The prompt to send. A plain string for a single turn, or an array of typed content parts for multi-part input. |
| instructions | string |
| temperature | number [ 0 .. 2 ] |
| max_output_tokens | number >= 0 |
| top_p | number [ 0 .. 1 ] |
| stream | boolean |
| tools | Array of arrays |
| tool_choice | any |
| text | object |
| reasoning | object |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "input": "value"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate text with gpt-5.6-terra via x402.
$0.016131 per call. Flat price, charged only on success.
Pay-per-call gpt-5.6-terra (text).
Request Body schema: application/jsonrequired
| input required | any The prompt to send. A plain string for a single turn, or an array of typed content parts for multi-part input. |
| instructions | string |
| temperature | number [ 0 .. 2 ] |
| max_output_tokens | number >= 0 |
| top_p | number [ 0 .. 1 ] |
| stream | boolean |
| tools | Array of arrays |
| tool_choice | any |
| text | object |
| reasoning | object |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "input": "value"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate text with kimi-k3 via x402.
$0.016132 per call. Flat price, charged only on success.
Pay-per-call kimi-k3 (text).
Request Body schema: application/jsonrequired
| messages required | Array of arrays Conversation so far, OpenAI-style: [{ role: "user", content: "..." }]. Roles are system, user and assistant. Send the whole history each call — the API is stateless. |
| temperature | number [ 0 .. 2 ] |
| max_tokens | number >= 0 |
| max_completion_tokens | number >= 0 |
| top_p | number [ 0 .. 1 ] |
| frequency_penalty | number [ -2 .. 2 ] |
| presence_penalty | number [ -2 .. 2 ] |
| stream | boolean |
| stream_options | object |
| tools | Array of arrays |
| tool_choice | any |
| response_format | any How the result is returned (e.g. a URL or base64 data). |
| modalities | Array of arrays |
| audio | object |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "messages": [
- {
- "role": "user",
- "content": "Summarize x402 in one sentence."
}
]
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate text with claude-sonnet-5 via x402.
$0.016132 per call. Flat price, charged only on success.
Pay-per-call claude-sonnet-5 (text).
Request Body schema: application/jsonrequired
| messages required | Array of arrays Conversation so far, OpenAI-style: [{ role: "user", content: "..." }]. Roles are system, user and assistant. Send the whole history each call — the API is stateless. |
| max_tokens required | number >= 0 Maximum tokens to generate. Billed at this ceiling rather than at actual usage, so ask for what you need — an unused allowance is still paid for. |
| system | string |
| stream | boolean |
| metadata | object |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "messages": [
- {
- "role": "user",
- "content": "Summarize x402 in one sentence."
}
], - "max_tokens": 0
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate text with claude-opus-5 via x402.
$0.026886 per call. Flat price, charged only on success.
Pay-per-call claude-opus-5 (text).
Request Body schema: application/jsonrequired
| messages required | Array of arrays Conversation so far, OpenAI-style: [{ role: "user", content: "..." }]. Roles are system, user and assistant. Send the whole history each call — the API is stateless. |
| max_tokens required | number >= 0 Maximum tokens to generate. Billed at this ceiling rather than at actual usage, so ask for what you need — an unused allowance is still paid for. |
| system | string |
| stream | boolean |
| metadata | object |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "messages": [
- {
- "role": "user",
- "content": "Summarize x402 in one sentence."
}
], - "max_tokens": 0
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate text with gpt-5.6-sol via x402.
$0.032262 per call. Flat price, charged only on success.
Pay-per-call gpt-5.6-sol (text).
Request Body schema: application/jsonrequired
| input required | any The prompt to send. A plain string for a single turn, or an array of typed content parts for multi-part input. |
| instructions | string |
| temperature | number [ 0 .. 2 ] |
| max_output_tokens | number >= 0 |
| top_p | number [ 0 .. 1 ] |
| stream | boolean |
| tools | Array of arrays |
| tool_choice | any |
| text | object |
| reasoning | object |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "input": "value"
}Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "output": { }
}Generate an image from a text prompt with any model.
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Capability endpoint — pick any matching model with GET /v1/models and pass it as { model }. Same pay-per-call charge as /v1/infer (402, then pay and retry); the per-model POST /x402/flux-2-pro-preview path also works.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id (see GET /v1/models). |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "flux-2-pro-preview",
- "prompt": "a red apple on a wooden table"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Generate a video from a text prompt or an image.
$0.0001–$60 per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Capability endpoint — pick any matching model with GET /v1/models and pass it as { model }. Same pay-per-call charge as /v1/infer (402, then pay and retry); the per-model POST /x402/wan-2.7-i2v path also works.
Request Body schema: application/jsonrequired
| model required | string Model id or full run id (see GET /v1/models). |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "model": "wan-2.7-i2v",
- "prompt": "a timelapse of clouds over mountains"
}Response samples
- 200
{- "model": "nano-banana-2",
- "costMicroUsd": 92400,
- "output": {
- "contentType": "image/png",
- "sizeBytes": 1834127
}
}Generate a video from text via an image step.
$0.445550 per call. Flat price, charged only on success.
Recipe: text → image → animated video (cheapest path to a video; better subject control). Multi-model pipeline from { prompt }. Override steps with { imageModel, videoModel }; { motionPrompt, duration, resolution } tune the video. Price = sum of all steps, charged once (402 → pay → retry) — the advertised amount is the DEFAULT pipeline; model/duration/resolution overrides re-price it. Returns each step's output + the final url.
Request Body schema: application/jsonrequired
| prompt required | string Text description of the subject/scene the pipeline should generate. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "an italian-brainrot cat-shark hybrid, 3d meme",
- "motionPrompt": "it dances and spins"
}Generate a video with audio from a text prompt.
$0.844300 per call. Flat price, charged only on success.
Recipe: text → image → video with native AUDIO. Multi-model pipeline from { prompt }. Override steps with { imageModel, videoModel }; { motionPrompt, duration, resolution } tune the video. Price = sum of all steps, charged once (402 → pay → retry) — the advertised amount is the DEFAULT pipeline; model/duration/resolution overrides re-price it. Returns each step's output + the final url.
Request Body schema: application/jsonrequired
| prompt required | string Text description of the subject/scene the pipeline should generate. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "an italian-brainrot cat-shark hybrid, 3d meme",
- "motionPrompt": "it dances and spins"
}Generate an HD video from text via an image.
$0.470750 per call. Flat price, charged only on success.
Recipe: text → higher-fidelity image → animated video. Multi-model pipeline from { prompt }. Override steps with { imageModel, videoModel }; { motionPrompt, duration, resolution } tune the video. Price = sum of all steps, charged once (402 → pay → retry) — the advertised amount is the DEFAULT pipeline; model/duration/resolution overrides re-price it. Returns each step's output + the final url.
Request Body schema: application/jsonrequired
| prompt required | string Text description of the subject/scene the pipeline should generate. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "an italian-brainrot cat-shark hybrid, 3d meme",
- "motionPrompt": "it dances and spins"
}Generate a random brainrot character video.
$0.997500 per call. Flat price, charged only on success.
Recipe: random Italian-brainrot character → animated video with audio (also the brainrot-video model). Multi-model pipeline. Override steps with { imageModel, videoModel }; { motionPrompt, duration, resolution } tune the video. Price = sum of all steps, charged once (402 → pay → retry) — the advertised amount is the DEFAULT pipeline; model/duration/resolution overrides re-price it. Returns each step's output + the final url.
Request Body schema: application/jsonoptional
| prompt | string Text description of the subject/scene the pipeline should generate. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "motionPrompt": "it dances and bounces"
}Run the image-to-video recipe via x402.
$0.445550–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call recipes/image-to-video via x402. Price = sum of the pipeline steps; min is the default-configuration price (overriding step models changes it).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "an italian-brainrot cat-shark, 3d meme"
}Run the image-to-video-audio recipe via x402.
$0.844300–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call recipes/image-to-video-audio via x402. Price = sum of the pipeline steps; min is the default-configuration price (overriding step models changes it).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a singing cartoon frog"
}Run the image-to-video-hd recipe via x402.
$0.470750–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call recipes/image-to-video-hd via x402. Price = sum of the pipeline steps; min is the default-configuration price (overriding step models changes it).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a crisp product shot of a sneaker"
}Run the brainrot-video recipe via x402.
$0.997500–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call recipes/brainrot-video via x402. Price = sum of the pipeline steps; min is the default-configuration price (overriding step models changes it).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "motionPrompt": "it dances and bounces energetically"
}Send a JSON-RPC call to a supported chain.
$0.002000 per call. Flat price, charged only on success.
Multi-chain JSON-RPC proxy — { chain, method, params }. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "chain": "base",
- "method": "eth_blockNumber",
- "params": [ ]
}Response samples
- 200
{- "tool": "tools/rpc",
- "costMicroUsd": 2000,
- "chain": "base",
- "result": "0x1a2b3c"
}Search the web and return ranked results.
$0.005000 per call. Flat price, charged only on success.
Web search — { q, count?: 1-20, country?: "ID", lang?: "id" }. Returns title, url and snippet per hit, plus which upstream answered. Providers are tried in order, so one being rate-limited falls through rather than failing the call. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "q": "x402 payment protocol",
- "count": 5
}Response samples
- 200
{- "tool": "tools/search",
- "costMicroUsd": 5000,
- "query": "x402 payment protocol",
- "provider": "brave",
- "count": 2,
- "results": [
- {
- "title": "x402 — an HTTP-native payment standard",
- "snippet": "Uses HTTP 402 to attach a USDC payment to any request."
}, - {
- "title": "Paying per API call with x402",
- "snippet": "A client pays the challenge and retries the same request."
}
]
}Convert text into embedding vectors.
$0.000500 per call. Flat price, charged only on success.
Text embeddings for search, clustering and RAG — { texts: ["..."] } or { text: "..." }. Up to 100 texts and 32,000 characters per call. Multilingual by default, so Indonesian and English embed into the same space and can be compared directly. Returns the model id and dimensions alongside the vectors. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "texts": [
- "harga tiket kereta ke Bandung",
- "train ticket price to Bandung"
]
}Response samples
- 200
{- "tool": "tools/embed",
- "costMicroUsd": 500,
- "model": "@cf/baai/bge-m3",
- "count": 2,
- "dimensions": 1024,
- "embeddings": [
- [
- 0.0121,
- -0.0334,
- 0.0087
], - [
- 0.0118,
- -0.0301,
- 0.0092
]
]
}Check text for unsafe content categories.
$0.001000 per call. Flat price, charged only on success.
Safety check for user-supplied text — { text }, up to 8,000 characters. Returns flagged plus the guard model hazard categories and its raw verdict. The verdict is that model judgement, not a legal determination: treat it as a signal in your own moderation flow. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "text": "I will find where you live."
}Response samples
- 200
{- "tool": "tools/moderate",
- "costMicroUsd": 1000,
- "model": "@cf/meta/llama-guard-3-8b",
- "flagged": true,
- "categories": [
- "S1"
], - "verdict": "unsafe\nS1",
- "chars": 27
}Fetch spot token prices by ticker symbol.
$0.002000 per call. Flat price, charged only on success.
Spot token prices — { symbols: "BTC,ETH", vs? } (CoinGecko ids also accepted via the same field or { ids }). Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "symbols": "BTC,ETH",
- "vs": "usd"
}Response samples
- 200
{- "tool": "tools/token-price",
- "costMicroUsd": 2000,
- "vs": "USD",
- "prices": {
- "BTC": 68000.12,
- "ETH": 3450.5
}, - "sources": {
- "BTC": "coinbase",
- "ETH": "coinbase"
}
}Convert fiat currencies at mid-market rates.
$0.002000 per call. Flat price, charged only on success.
Mid-market fiat exchange rates — { from?: "USD", to?: "IDR,EUR", amount? }. Omit to for every currency. Non-USD pairs are cross-rated via USD; reference rates, not dealable quotes. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "from": "USD",
- "to": "IDR,EUR",
- "amount": 100
}Response samples
- 200
{- "tool": "tools/exchange-rate",
- "costMicroUsd": 2000,
- "base": "USD",
- "rates": {
- "IDR": 18076.9467,
- "EUR": 0.875576
}, - "amount": 100,
- "converted": {
- "IDR": 1807694.6663,
- "EUR": 87.5576
}, - "as_of": "30 Jul 2026",
- "source": "open.er-api.com",
- "note": "Mid-market reference rates, not dealable quotes."
}Parse an Indonesian address into components.
$0.003000 per call. Flat price, charged only on success.
Parse a messy Indonesian address into components — { address }. kabupaten_kota and provinsi are resolved from official Kepmendagri data rather than from a model, so they cannot be invented, and verified reports where the model disagreed. Returns jalan, nomor, rt, rw, kelurahan, kecamatan, kabupaten_kota, provinsi, kode_pos, the official kode with coordinates, and a confidence. kecamatan/kelurahan/kode_pos are as written and unverified. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "address": "Jl. Merdeka No. 12 RT 03/RW 05, Gedong Air, Tanjung Karang Barat, Bandar Lampung 35152"
}Response samples
- 200
{- "tool": "tools/address-id",
- "costMicroUsd": 3000,
- "input": "Jl. Merdeka No. 12 RT 03/RW 05, Gedong Air, Tanjung Karang Barat, Bandar Lampung 35152",
- "parsed": {
- "jalan": "Merdeka",
- "nomor": "12",
- "rt": "3",
- "rw": "5",
- "kelurahan": "Gedong Air",
- "kecamatan": "Tanjung Karang Barat",
- "kabupaten_kota": "Kota Bandar Lampung",
- "provinsi": "Lampung",
- "kode_pos": "35152"
}, - "wilayah": {
- "kode": "18.71",
- "kabupaten_kota": "Kota Bandar Lampung",
- "provinsi": "Lampung",
- "lat": -5.42958,
- "lng": 105.26257
}, - "verified": {
- "kabupaten_kota": true,
- "provinsi": true
}, - "confidence": "high",
- "notes": [ ]
}Generate marketplace listing copy from a photo.
$0.008000 per call. Flat price, charged only on success.
Turn a product photo into ready-to-post marketplace copy — { image_url | image_base64 }. Returns title and description in BOTH Indonesian and English, plus category, condition, material, colours and search tags. Written from what is visible only: brands, sizes, materials and warranties are never inferred, and anything the photo does not show is null. Nothing is stored. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry). FILE INPUT: if the image is already on the web or your own storage, pass image_url — we fetch it server-side at datacenter speed, which is the fastest option by far. Sending it inline as image_base64 is simplest and stores nothing anywhere, but base64 adds ~33% to the bytes and you pay your own upload speed, so it is best under ~1MB. For a large local file, upload the RAW bytes to POST /v1/media (free, ≤40MB) and pass the URL: same transfer as base64 minus the 33%, and identity endpoints delete the object as soon as they have read it.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{
}Response samples
- 200
{- "tool": "tools/product-listing",
- "costMicroUsd": 8000,
- "listing": {
- "title_id": "Tas Selempang Kulit Coklat Pria",
- "title_en": "Men's Brown Leather Crossbody Bag",
- "description_id": "Tas selempang berbahan kulit warna coklat. Terdapat tali bahu yang bisa diatur dan satu kompartemen utama dengan ritsleting.",
- "description_en": "Brown leather crossbody bag with an adjustable shoulder strap and a single zipped main compartment.",
- "category": "Bags & Luggage",
- "condition": "new",
- "material": "Leather",
- "colors": [
- "coklat",
- "brown"
], - "tags": [
- "tas selempang",
- "tas kulit",
- "crossbody bag",
- "leather bag",
- "tas pria"
]
}, - "model": "@cf/mistralai/mistral-small-3.1-24b-instruct"
}Read an ID document into structured JSON.
$0.005000 per call. Flat price, charged only on success.
Read an identity document (Indonesian KTP/SIM/KK/NPWP, foreign passport or driving licence) into structured JSON — { image_url | image_base64 }. Indonesian documents also get structural NIK verification (region code, encoded birth date and gender) as a confidence signal, not proof of authenticity. Nothing is stored, and no face matching is performed. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry). FILE INPUT: if the image is already on the web or your own storage, pass image_url — we fetch it server-side at datacenter speed, which is the fastest option by far. Sending it inline as image_base64 is simplest and stores nothing anywhere, but base64 adds ~33% to the bytes and you pay your own upload speed, so it is best under ~1MB. For a large local file, upload the RAW bytes to POST /v1/media (free, ≤40MB) and pass the URL: same transfer as base64 minus the 33%, and identity endpoints delete the object as soon as they have read it.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{
}Response samples
- 200
{- "tool": "tools/ocr-id",
- "costMicroUsd": 5000,
- "fields": {
- "document_type": "KTP",
- "issuing_country": "INDONESIA",
- "id_number": "1871014102900002",
- "full_name": "BUDI SANTOSO",
- "birth_place": "BANDAR LAMPUNG",
- "birth_date": "01-02-1990",
- "gender": "PEREMPUAN",
- "address": "JL MERDEKA NO 12",
- "rt_rw": "003/005",
- "village": "GEDONG AIR",
- "district": "TANJUNG KARANG BARAT",
- "city": null,
- "province": null,
- "expiry_date": "SEUMUR HIDUP",
- "blood_type": "O",
- "nationality": "INDONESIA",
- "religion": "ISLAM",
- "marital_status": "BELUM MENIKAH",
- "sim_class": null
}, - "verification": {
- "ok": true,
- "format": true,
- "region": {
- "kode": "18.71",
- "kabupaten_kota": "Kota Bandar Lampung",
- "provinsi": "Lampung"
}, - "birth_date": "1990-02-01",
- "gender": "P",
- "agrees": {
- "birth_date": true,
- "gender": true
}, - "notes": [ ]
}, - "model": "@cf/mistralai/mistral-small-3.1-24b-instruct"
}Detect faces with boxes, age and gender.
$0.003000 per call. Flat price, charged only on success.
Detect faces → boxes + score + age/gender, no embeddings — { image_url | image_base64 }. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry). FILE INPUT: if the image is already on the web or your own storage, pass image_url — we fetch it server-side at datacenter speed, which is the fastest option by far. Sending it inline as image_base64 is simplest and stores nothing anywhere, but base64 adds ~33% to the bytes and you pay your own upload speed, so it is best under ~1MB. For a large local file, upload the RAW bytes to POST /v1/media (free, ≤40MB) and pass the URL: same transfer as base64 minus the 33%, and identity endpoints delete the object as soon as they have read it.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{
}Response samples
- 200
{- "tool": "tools/face-detect",
- "costMicroUsd": 3000
}Extract a 512-d embedding for each face.
$0.006000 per call. Flat price, charged only on success.
Detect every face → 512-d ArcFace embedding per face (+ bbox, score, age/gender) — { image_url | image_base64 }. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry). FILE INPUT: if the image is already on the web or your own storage, pass image_url — we fetch it server-side at datacenter speed, which is the fastest option by far. Sending it inline as image_base64 is simplest and stores nothing anywhere, but base64 adds ~33% to the bytes and you pay your own upload speed, so it is best under ~1MB. For a large local file, upload the RAW bytes to POST /v1/media (free, ≤40MB) and pass the URL: same transfer as base64 minus the 33%, and identity endpoints delete the object as soon as they have read it.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{
}Response samples
- 200
{- "tool": "tools/face-embed",
- "costMicroUsd": 6000
}Compare two faces for similarity and match.
$0.011000 per call. Flat price, charged only on success.
Compare two faces → cosine similarity + match — { a:{image_url|image_base64}, b:{image_url|image_base64} }. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry). FILE INPUT: if the image is already on the web or your own storage, pass image_url — we fetch it server-side at datacenter speed, which is the fastest option by far. Sending it inline as image_base64 is simplest and stores nothing anywhere, but base64 adds ~33% to the bytes and you pay your own upload speed, so it is best under ~1MB. For a large local file, upload the RAW bytes to POST /v1/media (free, ≤40MB) and pass the URL: same transfer as base64 minus the 33%, and identity endpoints delete the object as soon as they have read it.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{
}Response samples
- 200
{- "tool": "tools/face-compare",
- "costMicroUsd": 11000
}Read an ID document and match it to a selfie.
$0.015000 per call. Flat price, charged only on success.
Onboarding in one call: read an identity document AND compare the photo on it against a selfie — { id_image:{image_url|image_base64}, selfie:{image_url|image_base64} }. Cheaper than tools/ocr-id plus tools/face-compare separately, and the document is fetched once instead of twice. Returns { document:{fields,verification}, face:{similarity,match,threshold} } — measurements only, NO pass/fail verdict, because the threshold that matters is yours. There is no liveness check, so a photo of a photo can match: treat the result as a signal for your own decision, not proof of identity. Nothing is stored. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry). FILE INPUT: if the image is already on the web or your own storage, pass image_url — we fetch it server-side at datacenter speed, which is the fastest option by far. Sending it inline as image_base64 is simplest and stores nothing anywhere, but base64 adds ~33% to the bytes and you pay your own upload speed, so it is best under ~1MB. For a large local file, upload the RAW bytes to POST /v1/media (free, ≤40MB) and pass the URL: same transfer as base64 minus the 33%, and identity endpoints delete the object as soon as they have read it.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{
}Response samples
- 200
{- "tool": "tools/kyc-verify",
- "costMicroUsd": 15000,
- "document": {
- "fields": {
- "document_type": "KTP",
- "id_number": "1871014102900002",
- "full_name": "BUDI SANTOSO",
- "birth_date": "01-02-1990",
- "gender": "PEREMPUAN"
}, - "verification": {
- "ok": true,
- "region": {
- "kabupaten_kota": "Kota Bandar Lampung",
- "provinsi": "Lampung"
}, - "agrees": {
- "birth_date": true,
- "gender": true
}
}
}, - "face": {
- "similarity": 0.87,
- "match": true,
- "threshold": 0.35
}, - "model": "@cf/mistralai/mistral-small-3.1-24b-instruct"
}Summarize a YouTube video up to 60 minutes.
$0.150000 per call. Flat price, charged only on success.
Summarize a YouTube video (Gemini watches the URL) — { url, style?: bullets|paragraph|chapters, language? }; videos ≤60 min. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "style": "bullets"
}Response samples
- 200
{- "tool": "tools/youtube-summary",
- "costMicroUsd": 150000,
- "summary": "- The video explains ...\n- It then shows ...",
- "video": {
- "id": "dQw4w9WgXcQ",
- "title": "Example video",
- "channel": "Example Channel",
- "durationSeconds": 212
}
}Extract typed JSON from a page by schema.
$0.010000 per call. Flat price, charged only on success.
Render a page and return JSON matching a schema you declare — { url, schema, prompt? }. schema is { field: "description" } or { field: { type, description } }, type one of string|number|boolean|string[]. Values are coerced to the declared types; anything the page does not state is null and listed in missing rather than invented. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "schema": {
- "title": "the product name",
- "price": {
- "type": "number",
- "description": "listed price"
}
}
}Response samples
- 200
{- "tool": "tools/extract",
- "costMicroUsd": 10000,
- "data": {
- "title": "Widget Pro",
- "price": 249000,
- "in_stock": true
}, - "missing": [ ]
}Scrape a rendered page to clean markdown.
$0.005000 per call. Flat price, charged only on success.
Render a page (JS) → clean markdown — { url }. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{
}Response samples
- 200
{- "tool": "tools/scrape",
- "costMicroUsd": 5000,
- "markdown": "# Example\n\nSome page text..."
}Capture a page screenshot as a hosted PNG.
$0.005000 per call. Flat price, charged only on success.
Capture a page as PNG → hosted URL — { url, fullPage? }. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{
}Response samples
- 200
{- "tool": "tools/screenshot",
- "costMicroUsd": 5000,
}Render a branded 1200x630 OG card as a PNG.
$0.020000 per call. Flat price, charged only on success.
Render a 1200×630 branded OG/social card from a title → PNG URL. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "title": "Your headline",
- "subtitle": "a short tagline"
}Response samples
- 200
{- "tool": "tools/og-image",
- "costMicroUsd": 20000,
}Render a 1280x720 YouTube thumbnail as a PNG.
$0.020000 per call. Flat price, charged only on success.
Render a 1280×720 YouTube thumbnail (bold title over an optional background image) → PNG URL. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "title": "I tried this for 30 days",
- "subtitle": "the results",
}Response samples
- 200
{- "tool": "tools/youtube-thumbnail",
- "costMicroUsd": 20000,
}Render a shareable quote image as a PNG.
$0.020000 per call. Flat price, charged only on success.
Render a 1200×630 shareable quote image → PNG URL. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "quote": "Make it work, make it right, make it fast.",
- "author": "Kent Beck"
}Response samples
- 200
{- "tool": "tools/quote-card",
- "costMicroUsd": 20000,
}Render a code snippet as a dark window PNG.
$0.020000 per call. Flat price, charged only on success.
Render a code snippet as a clean dark window image → PNG URL. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "code": "console.log('hello')",
- "title": "app.js"
}Response samples
- 200
{- "tool": "tools/code-image",
- "costMicroUsd": 20000,
}Render a tweet-style card image as a PNG.
$0.020000 per call. Flat price, charged only on success.
Render a tweet-style card → PNG URL. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "text": "shipping > talking",
- "name": "GlianaAI",
- "handle": "glianalabs"
}Response samples
- 200
{- "tool": "tools/tweet-image",
- "costMicroUsd": 20000,
}Render meme text over an image as a PNG.
$0.020000 per call. Flat price, charged only on success.
Top/bottom Impact text over an image → PNG URL. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "top": "one does not simply",
- "bottom": "make a meme api"
}Response samples
- 200
{- "tool": "tools/meme",
- "costMicroUsd": 20000,
}Render a social card sized by preset as PNG.
$0.020000 per call. Flat price, charged only on success.
Templated social card sized by preset (og/instagram-square/story/linkedin/podcast) → PNG URL. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "preset": "instagram-square",
- "title": "Big news",
- "subtitle": "we shipped it"
}Response samples
- 200
{- "tool": "tools/card",
- "costMicroUsd": 20000,
}Scrape a URL title and render an OG card PNG.
$0.030000 per call. Flat price, charged only on success.
Scrape a URL's title + render a branded OG card from it → PNG URL. Utility endpoint (not an AI model) — flat price, paid like /v1/infer (402, then pay and retry).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{
}Response samples
- 200
{- "tool": "tools/auto-og",
- "costMicroUsd": 30000,
- "sourceTitle": "Example Domain",
}List Indonesian provinces and regencies.
Free — no API key, no payment, no signup.
No charge. Official Indonesian administrative regions — 38 provinsi and 514 kabupaten/kota per Kepmendagri No. 300.2.2-2430 Tahun 2025, with the official kode, capital, centroid, timezone, area and population. Call with ?kode=18 for one region (a provinsi also returns its regencies), ?q=bandung to search by name, ?induk=18 to list one province, or no params for all 38 provinces. Level 1-2 only — kecamatan and desa are not included.
query Parameters
| kode | string Official code, e.g. 18 (provinsi) or 18.71 (kabupaten/kota). |
| q | string Name search; best match first, kota preferred over kabupaten for an ambiguous name. |
| induk | string Parent provinsi code — lists every kabupaten/kota inside it. |
| level | string Enum: "provinsi" "kabupaten_kota" Restrict to provinsi or kabupaten_kota. |
Responses
Request samples
- cURL
- JavaScript
curl "https://api.glianalabs.com/v1/tools/wilayah" # Free — no payment, no key, no signup.
Response samples
- 200
{- "source": "Kepmendagri No. 300.2.2-2430 Tahun 2025 (via github.com/cahyadsn/wilayah)",
- "scope": "provinsi + kabupaten/kota (level 1-2)",
- "count": 3,
- "results": [
- {
- "kode": "32.73",
- "nama": "Kota Bandung",
- "level": "kabupaten_kota",
- "induk": "32",
- "ibukota": "Bandung",
- "lat": -6.92222,
- "lng": 107.60694,
- "timezone": "WIB",
- "utc_offset": 7,
- "luas_km2": 167.7,
- "penduduk": 2569107
}
]
}Verify an Indonesian NIK structurally.
Free — no API key, no payment, no signup.
No charge, no model call, instant. Checks an Indonesian NIK (national ID number) against arithmetic: 16-digit format, the region code in digits 1-4 resolved against official Kepmendagri data, and the birth date and gender the number encodes. Pass &birth_date=DD-MM-YYYY and &gender=L|P to cross-check what a user typed against what the number says — that is what catches a transposed digit. Proves consistency, NOT authenticity: a well-formed fabrication passes.
query Parameters
| nik required | string 16-digit Indonesian NIK. Spaces are tolerated. |
| birth_date | string Optional claimed birth date to cross-check, e.g. 01-02-1990. |
| gender | string Optional claimed gender to cross-check: L/LAKI-LAKI/M/MALE or P/PEREMPUAN/F/FEMALE. |
Responses
Request samples
- cURL
- JavaScript
curl "https://api.glianalabs.com/v1/tools/verify-nik" # Free — no payment, no key, no signup.
Response samples
- 200
{- "ok": true,
- "format": true,
- "region": {
- "kode": "18.71",
- "kabupaten_kota": "Kota Bandar Lampung",
- "provinsi": "Lampung"
}, - "birth_date": "1990-02-01",
- "gender": "P",
- "agrees": {
- "birth_date": true,
- "gender": true
}, - "notes": [ ],
- "note": "Structural check only: 16-digit format, the region code against official Kepmendagri data, and the birth date and gender the number encodes. It cannot tell a real NIK from a well-formed fabrication."
}Convert a number into Indonesian words.
Free — no API key, no payment, no signup.
No charge, no model call. Indonesian number-to-words for the amount-in-words line required on invoices, kwitansi and cheques. Pass ?n=249000 (Indonesian thousands separators accepted). Returns the plain words and the capitalised rupiah phrasing. Whole numbers only — decimals are not spelled.
query Parameters
| n required | string Whole number, e.g. 249000 or 249.000. |
Responses
Request samples
- cURL
- JavaScript
curl "https://api.glianalabs.com/v1/tools/terbilang" # Free — no payment, no key, no signup.
Response samples
- 200
{- "number": 249000,
- "terbilang": "dua ratus empat puluh sembilan ribu",
- "rupiah": "Dua ratus empat puluh sembilan ribu rupiah"
}Verify an Indonesian tax number structurally.
Free — no API key, no payment, no signup.
No charge, no model call. A 16-digit NPWP is the holder's NIK (since 2024) and gets the full region, birth-date and gender check; the 15-digit legacy form is decomposed into taxpayer id, KPP code and branch code and checked for structure only. Neither proves the number was actually issued — checks says exactly what was tested.
query Parameters
| npwp required | string 15 or 16 digits; dots and dashes ignored. |
Responses
Request samples
- cURL
- JavaScript
curl "https://api.glianalabs.com/v1/tools/verify-npwp" # Free — no payment, no key, no signup.
Response samples
- 200
{- "ok": true,
- "format": "legacy15",
- "normalized": "01.234.567.8-901.000",
- "parts": {
- "taxpayer_id": "012345678",
- "kpp_code": "901",
- "branch_code": "000",
- "is_head_office": true
}, - "nik": null,
- "checks": [
- "15-digit legacy format: length and structure only"
], - "notes": [
- "Structure only — the legacy check digit is not verified, so a well-formed number that was never issued will pass."
]
}Parse a QRIS code and optionally set an amount.
Free — no API key, no payment, no signup.
No charge, no model call. Decodes a QRIS payment code (EMVCo TLV) into merchant name, city, NMID, acquirer, MCC, currency and amount, and reports whether the CRC-16 is intact — valid_crc false means the code is damaged or mistyped and nothing else should be trusted. Add &amount=50000 to also get the same merchant code with that amount set (the standard static-to-dynamic conversion): the merchant account template is preserved byte for byte, the CRC recomputed, and the result re-parsed before it is returned. Does NOT mint a merchant QR — the NMID is issued by an acquirer and is never invented. Test with your acquirer before production use.
query Parameters
| payload required | string The QRIS string from the QR code. |
| amount | string Optional amount to set, e.g. 50000. Refused if the source CRC is invalid. |
Responses
Request samples
- cURL
- JavaScript
curl "https://api.glianalabs.com/v1/tools/qris" # Free — no payment, no key, no signup.
Response samples
- 200
{- "valid_crc": true,
- "crc": {
- "found": "A1B2",
- "computed": "A1B2"
}, - "type": "static",
- "merchant_name": "WARUNG GLIANA",
- "merchant_city": "BANDAR LAMPUNG",
- "country": "ID",
- "currency": "360",
- "amount": null,
- "mcc": "5814",
- "nmid": "ID1234567890123",
- "acquirer": "ID.CO.QRIS.WWW"
}Get Islamic prayer times for a place and date.
Free — no API key, no payment, no signup.
No charge. Jadwal sholat (imsak, subuh, terbit, dzuhur, ashar, maghrib, isya) computed from solar position. Pass ?city=Bandar Lampung (any Indonesian kabupaten/kota name or kode — the coordinate and timezone come from the official wilayah data) or ?lat=&lng=&tz=. ?days=30 returns a whole month in one call. Methods: kemenag (default, Indonesia), mwl, isna, egypt, makkah, karachi; madhab shafi (default) or hanafi changes ashar only. Calculated times are typically within 1-2 minutes of the official Kemenag table and are not a substitute for a local mosque schedule. Where the sun never reaches the required depression (high latitudes in summer) the affected times are null rather than guessed.
query Parameters
| city | string Indonesian kabupaten/kota name or kode. Alternative to lat/lng/tz. |
| lat | number Latitude, -90..90. Requires lng. |
| lng | number Longitude, -180..180. |
| tz | number UTC offset in hours (7 WIB, 8 WITA, 9 WIT). Defaults to the offset implied by lng. |
| date | string YYYY-MM-DD. Defaults to today in the target timezone. |
| days | integer [ 1 .. 31 ] Consecutive days to return, 1-31. Default 1. |
| method | string Enum: "kemenag" "mwl" "isna" "egypt" "makkah" "karachi" Calculation authority. |
| madhab | string Enum: "shafi" "hanafi" Asr shadow rule. |
Responses
Request samples
- cURL
- JavaScript
curl "https://api.glianalabs.com/v1/tools/prayer-times" # Free — no payment, no key, no signup.
Response samples
- 200
{- "location": {
- "kode": "18.71",
- "nama": "Kota Bandar Lampung",
- "level": "kabupaten_kota",
- "induk": "18",
- "ibukota": "Bandar Lampung",
- "lat": -5.42958,
- "lng": 105.26257,
- "timezone": "WIB",
- "utc_offset": 7
}, - "method": {
- "id": "kemenag",
- "label": "Kementerian Agama Republik Indonesia",
- "fajr_angle": 20,
- "isha": 18,
- "ihtiyati": true
}, - "madhab": "shafi",
- "note": "Calculated from solar position, typically within 1-2 minutes of the official Kemenag table. Not a substitute for your local mosque schedule.",
- "date": "2026-07-30",
- "times": {
- "imsak": "04:36",
- "fajr": "04:50",
- "sunrise": "06:07",
- "dhuhr": "12:07",
- "asr": "15:30",
- "maghrib": "18:04",
- "isha": "19:16"
}
}Run the search tool via x402.
$0.005000 per call. Flat price, charged only on success.
Pay-per-call tools/search via x402.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "q": "x402 payment protocol",
- "count": 5
}Run the embed tool via x402.
$0.000500 per call. Flat price, charged only on success.
Pay-per-call tools/embed via x402.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "texts": [
- "harga tiket kereta ke Bandung",
- "train ticket price to Bandung"
]
}Run the moderate tool via x402.
$0.001000 per call. Flat price, charged only on success.
Pay-per-call tools/moderate via x402.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "text": "I will find where you live."
}Detect faces in an image via x402.
$0.003000 per call. Flat price, charged only on success.
Pay-per-call tools/face-detect via x402. FILE INPUT: if the image is already on the web or your own storage, pass image_url — we fetch it server-side at datacenter speed, which is the fastest option by far. Sending it inline as image_base64 is simplest and stores nothing anywhere, but base64 adds ~33% to the bytes and you pay your own upload speed, so it is best under ~1MB. For a large local file, upload the RAW bytes to POST /v1/media (free, ≤40MB) and pass the URL: same transfer as base64 minus the 33%, and identity endpoints delete the object as soon as they have read it.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{
}Extract face embeddings via x402.
$0.006000 per call. Flat price, charged only on success.
Pay-per-call tools/face-embed via x402. FILE INPUT: if the image is already on the web or your own storage, pass image_url — we fetch it server-side at datacenter speed, which is the fastest option by far. Sending it inline as image_base64 is simplest and stores nothing anywhere, but base64 adds ~33% to the bytes and you pay your own upload speed, so it is best under ~1MB. For a large local file, upload the RAW bytes to POST /v1/media (free, ≤40MB) and pass the URL: same transfer as base64 minus the 33%, and identity endpoints delete the object as soon as they have read it.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{
}Compare two face images via x402.
$0.011000 per call. Flat price, charged only on success.
Pay-per-call tools/face-compare via x402. FILE INPUT: if the image is already on the web or your own storage, pass image_url — we fetch it server-side at datacenter speed, which is the fastest option by far. Sending it inline as image_base64 is simplest and stores nothing anywhere, but base64 adds ~33% to the bytes and you pay your own upload speed, so it is best under ~1MB. For a large local file, upload the RAW bytes to POST /v1/media (free, ≤40MB) and pass the URL: same transfer as base64 minus the 33%, and identity endpoints delete the object as soon as they have read it.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{
}Fetch spot token prices via x402.
$0.002000 per call. Flat price, charged only on success.
Pay-per-call tools/token-price via x402.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "symbols": "BTC,ETH",
- "vs": "usd"
}Run the exchange-rate tool via x402.
$0.002000 per call. Flat price, charged only on success.
Pay-per-call tools/exchange-rate via x402.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "from": "USD",
- "to": "IDR,EUR",
- "amount": 100
}Run the ocr-id tool via x402.
$0.005000 per call. Flat price, charged only on success.
Pay-per-call tools/ocr-id via x402. FILE INPUT: if the image is already on the web or your own storage, pass image_url — we fetch it server-side at datacenter speed, which is the fastest option by far. Sending it inline as image_base64 is simplest and stores nothing anywhere, but base64 adds ~33% to the bytes and you pay your own upload speed, so it is best under ~1MB. For a large local file, upload the RAW bytes to POST /v1/media (free, ≤40MB) and pass the URL: same transfer as base64 minus the 33%, and identity endpoints delete the object as soon as they have read it.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{
}Run the kyc-verify tool via x402.
$0.015000 per call. Flat price, charged only on success.
Pay-per-call tools/kyc-verify via x402. FILE INPUT: if the image is already on the web or your own storage, pass image_url — we fetch it server-side at datacenter speed, which is the fastest option by far. Sending it inline as image_base64 is simplest and stores nothing anywhere, but base64 adds ~33% to the bytes and you pay your own upload speed, so it is best under ~1MB. For a large local file, upload the RAW bytes to POST /v1/media (free, ≤40MB) and pass the URL: same transfer as base64 minus the 33%, and identity endpoints delete the object as soon as they have read it.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{
}Run the extract tool via x402.
$0.010000 per call. Flat price, charged only on success.
Pay-per-call tools/extract via x402.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "schema": {
- "title": "the product name",
- "price": {
- "type": "number",
- "description": "listed price"
}, - "in_stock": {
- "type": "boolean"
}
}
}Run the product-listing tool via x402.
$0.008000 per call. Flat price, charged only on success.
Pay-per-call tools/product-listing via x402. FILE INPUT: if the image is already on the web or your own storage, pass image_url — we fetch it server-side at datacenter speed, which is the fastest option by far. Sending it inline as image_base64 is simplest and stores nothing anywhere, but base64 adds ~33% to the bytes and you pay your own upload speed, so it is best under ~1MB. For a large local file, upload the RAW bytes to POST /v1/media (free, ≤40MB) and pass the URL: same transfer as base64 minus the 33%, and identity endpoints delete the object as soon as they have read it.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{
}Send a JSON-RPC call via x402.
$0.002000 per call. Flat price, charged only on success.
Pay-per-call tools/rpc via x402.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "chain": "base",
- "method": "eth_blockNumber",
- "params": [ ]
}Render an OG social card via x402.
$0.020000 per call. Flat price, charged only on success.
Pay-per-call tools/og-image via x402.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "title": "GlianaAI",
- "subtitle": "pay-per-call AI, no signup"
}Render a YouTube thumbnail via x402.
$0.020000 per call. Flat price, charged only on success.
Pay-per-call tools/youtube-thumbnail via x402.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "title": "I built an AI API",
- "subtitle": "in one weekend"
}Render a quote card image via x402.
$0.020000 per call. Flat price, charged only on success.
Pay-per-call tools/quote-card via x402.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "quote": "Make it work, make it right, make it fast.",
- "author": "Kent Beck"
}Render a code snippet image via x402.
$0.020000 per call. Flat price, charged only on success.
Pay-per-call tools/code-image via x402.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "code": "const x = 42;",
- "title": "app.js"
}Render a tweet-style card via x402.
$0.020000 per call. Flat price, charged only on success.
Pay-per-call tools/tweet-image via x402.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "text": "shipping > talking",
- "name": "GlianaAI",
- "handle": "glianalabs"
}Render a meme image via x402.
$0.020000 per call. Flat price, charged only on success.
Pay-per-call tools/meme via x402.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "top": "one does not simply",
- "bottom": "ship on friday"
}Render a social card image via x402.
$0.020000 per call. Flat price, charged only on success.
Pay-per-call tools/card via x402.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "preset": "instagram-square",
- "title": "Big news",
- "subtitle": "we shipped it"
}Summarize a YouTube video via x402.
$0.150000 per call. Flat price, charged only on success.
Pay-per-call tools/youtube-summary via x402.
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "style": "bullets"
}Generate a video from text via an image step.
$0.445550 per call. Flat price, charged only on success.
Recipe: text → image → animated video (cheapest path to a video; better subject control). Multi-model pipeline from { prompt }. Override steps with { imageModel, videoModel }; { motionPrompt, duration, resolution } tune the video. Price = sum of all steps, charged once (402 → pay → retry) — the advertised amount is the DEFAULT pipeline; model/duration/resolution overrides re-price it. Returns each step's output + the final url.
Request Body schema: application/jsonrequired
| prompt required | string Text description of the subject/scene the pipeline should generate. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "an italian-brainrot cat-shark hybrid, 3d meme",
- "motionPrompt": "it dances and spins"
}Generate a video with audio from a text prompt.
$0.844300 per call. Flat price, charged only on success.
Recipe: text → image → video with native AUDIO. Multi-model pipeline from { prompt }. Override steps with { imageModel, videoModel }; { motionPrompt, duration, resolution } tune the video. Price = sum of all steps, charged once (402 → pay → retry) — the advertised amount is the DEFAULT pipeline; model/duration/resolution overrides re-price it. Returns each step's output + the final url.
Request Body schema: application/jsonrequired
| prompt required | string Text description of the subject/scene the pipeline should generate. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "an italian-brainrot cat-shark hybrid, 3d meme",
- "motionPrompt": "it dances and spins"
}Generate an HD video from text via an image.
$0.470750 per call. Flat price, charged only on success.
Recipe: text → higher-fidelity image → animated video. Multi-model pipeline from { prompt }. Override steps with { imageModel, videoModel }; { motionPrompt, duration, resolution } tune the video. Price = sum of all steps, charged once (402 → pay → retry) — the advertised amount is the DEFAULT pipeline; model/duration/resolution overrides re-price it. Returns each step's output + the final url.
Request Body schema: application/jsonrequired
| prompt required | string Text description of the subject/scene the pipeline should generate. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "an italian-brainrot cat-shark hybrid, 3d meme",
- "motionPrompt": "it dances and spins"
}Generate a random brainrot character video.
$0.997500 per call. Flat price, charged only on success.
Recipe: random Italian-brainrot character → animated video with audio (also the brainrot-video model). Multi-model pipeline. Override steps with { imageModel, videoModel }; { motionPrompt, duration, resolution } tune the video. Price = sum of all steps, charged once (402 → pay → retry) — the advertised amount is the DEFAULT pipeline; model/duration/resolution overrides re-price it. Returns each step's output + the final url.
Request Body schema: application/jsonoptional
| prompt | string Text description of the subject/scene the pipeline should generate. |
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "motionPrompt": "it dances and bounces"
}Run the image-to-video recipe via x402.
$0.445550–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call recipes/image-to-video via x402. Price = sum of the pipeline steps; min is the default-configuration price (overriding step models changes it).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "an italian-brainrot cat-shark, 3d meme"
}Run the image-to-video-audio recipe via x402.
$0.844300–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call recipes/image-to-video-audio via x402. Price = sum of the pipeline steps; min is the default-configuration price (overriding step models changes it).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a singing cartoon frog"
}Run the image-to-video-hd recipe via x402.
$0.470750–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call recipes/image-to-video-hd via x402. Price = sum of the pipeline steps; min is the default-configuration price (overriding step models changes it).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "prompt": "a crisp product shot of a sneaker"
}Run the brainrot-video recipe via x402.
$0.997500–$undefined per call, depending on model and input. Exact price is returned in the 402 challenge before you pay, or up front from GET /v1/price?model=.
Pay-per-call recipes/brainrot-video via x402. Price = sum of the pipeline steps; min is the default-configuration price (overriding step models changes it).
Request Body schema: application/jsonrequired
| property name* additional property | any |
Responses
Request samples
- Payload
- cURL
- JavaScript
{- "motionPrompt": "it dances and bounces energetically"
}Check the prepaid balance behind an API key.
Free — no API key, no payment, no signup.
No charge. Send Authorization: Bearer gk_…. Callers who cannot settle per call from a wallet can instead hold a prepaid balance (topped up in the dashboard) and spend it with an API key; every paid endpoint accepts either. Returns the remaining balance in micro-USD.
Responses
Request samples
- cURL
- JavaScript
curl "https://api.glianalabs.com/v1/keys/balance" # Free — no payment, no key, no signup.
Response samples
- 200
{- "account_id": "string",
- "balance_micro_usd": 0,
- "balance_usd": "string"
}List all available models with per-call prices.
Free — no API key, no payment, no signup.
No charge — browsing the catalog costs nothing.
Responses
Request samples
- cURL
- JavaScript
curl "https://api.glianalabs.com/v1/models" # Free — no payment, no key, no signup.
Response samples
- 200
{- "models": [
- { }
]
}Get a model's input fields, types and ranges.
Free — no API key, no payment, no signup.
No charge. Pass ?model=fileRef flag for file inputs (image/video/audio) — those take a public URL; upload a local file at POST /v1/media.
query Parameters
| model required | string Model id or full run id (see GET /v1/models). |
Responses
Request samples
- cURL
- JavaScript
curl "https://api.glianalabs.com/v1/schema" # Free — no payment, no key, no signup.
Response samples
- 200
{- "model": "string",
- "required": [
- "string"
], - "props": { }
}Get the exact price of a single model call.
Free — no API key, no payment, no signup.
No charge. Pass ?model=
query Parameters
| model required | string Model id or full run id (see GET /v1/models). |
Responses
Request samples
- cURL
- JavaScript
curl "https://api.glianalabs.com/v1/price" # Free — no payment, no key, no signup.
Response samples
- 200
{- "model": "string",
- "costMicroUsd": 0,
- "unit": "string",
- "units": 0
}Upload a source file and get a hosted URL.
Free — no API key, no payment, no signup.
No charge. Upload a video / image / audio file to use as a model input (e.g. an image-to-video source, or a video-to-video video_uri). Send the raw file as the request body with its Content-Type; max 40 MB. Returns { url } — pass that URL into the model field. Use this when an input is too big for an inline value, or you don't already have a public URL. FILE INPUT: if the image is already on the web or your own storage, pass image_url — we fetch it server-side at datacenter speed, which is the fastest option by far. Sending it inline as image_base64 is simplest and stores nothing anywhere, but base64 adds ~33% to the bytes and you pay your own upload speed, so it is best under ~1MB. For a large local file, upload the RAW bytes to POST /v1/media (free, ≤40MB) and pass the URL: same transfer as base64 minus the 33%, and identity endpoints delete the object as soon as they have read it.
Request Body schema: required
Raw file bytes. Content-Type must be video/, image/, or audio/*.
Responses
Request samples
- cURL
- JavaScript
curl -X POST "https://api.glianalabs.com/v1/media" # Free — no payment, no key, no signup.
Response samples
- 200
{- "contentType": "string",
- "sizeBytes": 0
}Fetch a stored media file by its key.
Free — no API key, no payment, no signup.
No charge. Serves an uploaded input or a generated output by the key from its /v1/media URL (32-hex id, optional file extension). Responds with the raw file bytes.
path Parameters
| key required | string^[0-9a-f]{32}(\.[a-z0-9]+)?$ Media key from a /v1/media URL — 32 hex chars, optionally followed by a file extension (e.g. 0f...aa.png). |
Responses
Request samples
- cURL
- JavaScript
curl "https://api.glianalabs.com/v1/media/YOUR_KEY" # Free — no payment, no key, no signup.