{"openapi":"3.0.0","info":{"description":"ArliAI serverless LLM inference API — OpenAI-compatible; static Bearer key.","version":null},"servers":[{"description":"ArliAI serverless LLM inference API — OpenAI-compatible; static Bearer key.","url":"https://api.apirails.com/arliai"}],"paths":{"/v1/chat/completions":{"post":{"tags":["Chat"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/v1/chat/completions"},"summary":"Create chat completion","description":"Chat completions: takes a list of messages and returns a generated response. Supports Vision Language Models by sending image_url parts in the user message content.","security":[{"bearerAuth":[]}],"requestBody":{"description":"","required":true,"content":{"application/json":{"schema":{"type":"object","required":[],"properties":{"bad_words":{"type":"array","description":"Disallows these substrings from appearing in the output (enforced via token-level bans).","items":{"type":"string"}},"echo":{"type":"boolean","description":"Text completion: echoes the prompt back as part of the output.","enum":[true,false]},"frequency_penalty":{"type":"number","description":"OpenAI-style penalty: penalty scales with how often a token has appeared. Range typically [-2.0, 2.0]."},"ignore_eos":{"type":"boolean","description":"When true, the EOS token does not terminate generation — the model keeps going until max_tokens or a stop condition.","enum":[true,false]},"include_reasoning":{"type":"boolean","description":"Whether to include the model's reasoning/thinking trace in the response.","enum":[true,false]},"include_stop_str_in_output":{"type":"boolean","description":"When true, the matching stop string/stop token is included in the returned text instead of being stripped.","enum":[true,false]},"length_penalty":{"type":"number","description":"Used with use_beam_search: exponentially scales beam scores by sequence length. 1.0 = neutral."},"logit_bias":{"type":"object","description":"Map of token ID (as string) to bias added to that token's logit. Range typically [-100, 100].","properties":{}},"logprobs":{"type":"boolean","description":"Whether to return logprobs at all. Pair with top_logprobs for the count.","enum":[true,false]},"max_completion_tokens":{"type":"number","description":"OpenAI's current name for the max output length. Preferred over max_tokens for chat. Takes precedence when both are set."},"messages":{"type":"array","description":"The conversation as a list of message objects (role, content, plus optional tool_calls, name, etc.).","required":true,"items":{"type":"object","properties":{"content":{"type":"string","description":"Content of the message. For Vision Language Models the user content may be an array of text and image_url parts.","required":true},"role":{"type":"string","description":"Role of the message sender.","required":true,"enum":["system","user","assistant","tool"]}}}},"min_p":{"type":"number","description":"Min-p sampling: keeps only tokens whose probability is at least min_p x max_token_probability. 0.0 = disabled."},"min_tokens":{"type":"number","description":"Force the model to generate at least this many tokens before any stop string or stop_token_ids can terminate generation."},"model":{"type":"string","description":"The model name to serve the request from. If null, the default served model is used."},"n":{"type":"number","description":"Number of independent completions to generate for the prompt."},"parallel_tool_calls":{"type":"boolean","description":"Whether the model may emit multiple tool calls in a single response.","enum":[true,false]},"presence_penalty":{"type":"number","description":"OpenAI-style penalty: tokens that have appeared at least once get their logits reduced. Range typically [-2.0, 2.0]."},"prompt_logprobs":{"type":"number","description":"Return logprobs for each prompt token. Integer = number of top logprobs per prompt token; -1 = all."},"reasoning_effort":{"type":"string","description":"Controls how much reasoning/thinking effort reasoning models spend. Lower values = faster, fewer thinking tokens.","enum":["none","minimal","low","medium","high","xhigh","max"]},"repetition_penalty":{"type":"number","description":"HuggingFace-style multiplicative penalty: divides the logit of any already-seen token by this value. 1.0 = no penalty."},"response_format":{"type":"object","description":"Constrains the output format. Accepted values: {\"type\": \"text\"}; {\"type\": \"json_object\"}; {\"type\": \"json_schema\", \"json_schema\": {\"schema\": {...}}}.","properties":{"type":{"type":"string","description":"The format type.","enum":["text","json_object","json_schema"]}}},"seed":{"type":"number","description":"RNG seed for reproducible sampling. Same seed + same prompt + same params = same output."},"skip_special_tokens":{"type":"boolean","description":"When detokenizing output back to text, strip special tokens.","enum":[true,false]},"spaces_between_special_tokens":{"type":"boolean","description":"Insert spaces between special tokens during detokenization for readability.","enum":[true,false]},"stop":{"type":"array","description":"Stop strings — generation halts when any of these substrings appears in the output.","items":{"type":"string"}},"stop_token_ids":{"type":"array","description":"Stop at these specific token IDs (more efficient than string matching).","items":{"type":"number"}},"stream":{"type":"boolean","description":"Return tokens incrementally via Server-Sent Events (SSE) as they're generated.","enum":[true,false]},"temperature":{"type":"number","description":"Controls randomness in sampling. Lower values make output more deterministic; 0.0 forces greedy decoding."},"thinking_token_budget":{"type":"number","description":"Hard cap on the number of tokens the model may spend on internal thinking. -1 = unlimited (treated as unset)."},"tool_choice":{"type":"string","description":"Controls tool use: none, auto, required, or {\"type\": \"function\", \"function\": {\"name\": \"...\"}} to force a specific function.","enum":["none","auto","required"]},"tools":{"type":"array","description":"List of tool/function definitions the model may call. Each tool has a type (\"function\") and a function (name, description, parameters JSON Schema).","items":{"type":"object","properties":{"type":{"type":"string","description":"Tool type.","enum":["function"]},"function":{"type":"object","description":"Function definition."}}}},"top_k":{"type":"number","description":"Only sample from the top k highest-probability tokens at each step. 0 or -1 = disabled."},"top_logprobs":{"type":"number","description":"Number of top alternative tokens (with logprobs) to return at each generated position. Requires logprobs: true. Max typically 20."},"top_p":{"type":"number","description":"Nucleus sampling: only consider the smallest set of tokens whose cumulative probability reaches top_p. 1.0 = disabled."},"truncate_prompt_tokens":{"type":"number","description":"Truncate the prompt to this many tokens before generation. -1 = keep all tokens."},"use_beam_search":{"type":"boolean","description":"Switch from random sampling to beam search. n becomes the beam width.","enum":[true,false]},"user":{"type":"string","description":"OpenAI-style end-user identifier. Included only for API compatibility."}}},"example":{"bad_words":["spam"],"echo":"","frequency_penalty":"","ignore_eos":"","include_reasoning":true,"include_stop_str_in_output":"","length_penalty":1,"logit_bias":{},"logprobs":"","max_completion_tokens":512,"messages":[{"content":"Hello!","role":"user"}],"min_p":"","min_tokens":"","model":"Gemma-4-31B-Lilith-v1.0","n":1,"parallel_tool_calls":true,"presence_penalty":"","prompt_logprobs":"","reasoning_effort":"medium","repetition_penalty":1,"response_format":{},"seed":42,"skip_special_tokens":true,"spaces_between_special_tokens":true,"stop":["\n\nUser:"],"stop_token_ids":[2],"stream":"","temperature":1,"thinking_token_budget":-1,"tool_choice":"auto","tools":[],"top_k":"","top_logprobs":"","top_p":1,"truncate_prompt_tokens":-1,"use_beam_search":"","user":""}}}}}},"/v1/completions":{"post":{"tags":["Text Completions"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/v1/completions"},"summary":"Create text completion","description":"Text completions: takes a prompt and returns a generated response.","security":[{"bearerAuth":[]}],"requestBody":{"description":"","required":true,"content":{"application/json":{"schema":{"type":"object","required":[],"properties":{"bad_words":{"type":"array","description":"Disallows these substrings from appearing in the output (enforced via token-level bans).","items":{"type":"string"}},"echo":{"type":"boolean","description":"Text completion: echoes the prompt back as part of the output.","enum":[true,false]},"frequency_penalty":{"type":"number","description":"OpenAI-style penalty: penalty scales with how often a token has appeared. Range typically [-2.0, 2.0]."},"ignore_eos":{"type":"boolean","description":"When true, the EOS token does not terminate generation — the model keeps going until max_tokens or a stop condition.","enum":[true,false]},"include_reasoning":{"type":"boolean","description":"Whether to include the model's reasoning/thinking trace in the response.","enum":[true,false]},"include_stop_str_in_output":{"type":"boolean","description":"When true, the matching stop string/stop token is included in the returned text instead of being stripped.","enum":[true,false]},"length_penalty":{"type":"number","description":"Used with use_beam_search: exponentially scales beam scores by sequence length. 1.0 = neutral."},"logit_bias":{"type":"object","description":"Map of token ID (as string) to bias added to that token's logit. Range typically [-100, 100].","properties":{}},"logprobs":{"type":"boolean","description":"Whether to return logprobs at all. Pair with top_logprobs for the count.","enum":[true,false]},"max_tokens":{"type":"number","description":"Maximum number of tokens to generate. Bounded server-side by max_model_len - prompt_length."},"min_p":{"type":"number","description":"Min-p sampling: keeps only tokens whose probability is at least min_p x max_token_probability. 0.0 = disabled."},"min_tokens":{"type":"number","description":"Force the model to generate at least this many tokens before any stop string or stop_token_ids can terminate generation."},"model":{"type":"string","description":"The model name to serve the request from. If null, the default served model is used."},"n":{"type":"number","description":"Number of independent completions to generate for the prompt."},"presence_penalty":{"type":"number","description":"OpenAI-style penalty: tokens that have appeared at least once get their logits reduced. Range typically [-2.0, 2.0]."},"prompt":{"type":"string","description":"The input text or token IDs to complete. Can be a single string, a batch of strings, or pre-tokenized ID lists.","required":true},"prompt_logprobs":{"type":"number","description":"Return logprobs for each prompt token. Integer = number of top logprobs per prompt token; -1 = all."},"reasoning_effort":{"type":"string","description":"Controls how much reasoning/thinking effort reasoning models spend. Lower values = faster, fewer thinking tokens.","enum":["none","minimal","low","medium","high","xhigh","max"]},"repetition_penalty":{"type":"number","description":"HuggingFace-style multiplicative penalty: divides the logit of any already-seen token by this value. 1.0 = no penalty."},"response_format":{"type":"object","description":"Constrains the output format. Accepted values: {\"type\": \"text\"}; {\"type\": \"json_object\"}; {\"type\": \"json_schema\", \"json_schema\": {\"schema\": {...}}}.","properties":{"type":{"type":"string","description":"The format type.","enum":["text","json_object","json_schema"]}}},"seed":{"type":"number","description":"RNG seed for reproducible sampling. Same seed + same prompt + same params = same output."},"skip_special_tokens":{"type":"boolean","description":"When detokenizing output back to text, strip special tokens.","enum":[true,false]},"spaces_between_special_tokens":{"type":"boolean","description":"Insert spaces between special tokens during detokenization for readability.","enum":[true,false]},"stop":{"type":"array","description":"Stop strings — generation halts when any of these substrings appears in the output.","items":{"type":"string"}},"stop_token_ids":{"type":"array","description":"Stop at these specific token IDs (more efficient than string matching).","items":{"type":"number"}},"stream":{"type":"boolean","description":"Return tokens incrementally via Server-Sent Events (SSE) as they're generated.","enum":[true,false]},"temperature":{"type":"number","description":"Controls randomness in sampling. Lower values make output more deterministic; 0.0 forces greedy decoding."},"thinking_token_budget":{"type":"number","description":"Hard cap on the number of tokens the model may spend on internal thinking. -1 = unlimited (treated as unset)."},"top_k":{"type":"number","description":"Only sample from the top k highest-probability tokens at each step. 0 or -1 = disabled."},"top_logprobs":{"type":"number","description":"Number of top alternative tokens (with logprobs) to return at each generated position. Requires logprobs: true. Max typically 20."},"top_p":{"type":"number","description":"Nucleus sampling: only consider the smallest set of tokens whose cumulative probability reaches top_p. 1.0 = disabled."},"truncate_prompt_tokens":{"type":"number","description":"Truncate the prompt to this many tokens before generation. -1 = keep all tokens."},"use_beam_search":{"type":"boolean","description":"Switch from random sampling to beam search. n becomes the beam width.","enum":[true,false]},"user":{"type":"string","description":"OpenAI-style end-user identifier. Included only for API compatibility."}}},"example":{"bad_words":["spam"],"echo":"","frequency_penalty":"","ignore_eos":"","include_reasoning":true,"include_stop_str_in_output":"","length_penalty":1,"logit_bias":{},"logprobs":"","max_tokens":50,"min_p":"","min_tokens":"","model":"Gemma-4-31B-Lilith-v1.0","n":1,"presence_penalty":"","prompt":"Once upon a time","prompt_logprobs":"","reasoning_effort":"medium","repetition_penalty":1,"response_format":{},"seed":42,"skip_special_tokens":true,"spaces_between_special_tokens":true,"stop":["\n\nUser:"],"stop_token_ids":[2],"stream":"","temperature":1,"thinking_token_budget":-1,"top_k":"","top_logprobs":"","top_p":1,"truncate_prompt_tokens":-1,"use_beam_search":"","user":""}}}}}},"/v1/tokenize":{"post":{"tags":["Tokenization"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/v1/tokenize"},"summary":"Tokenize text","description":"Tokenizes the given text.","security":[{"bearerAuth":[]}],"requestBody":{"description":"","required":true,"content":{"application/json":{"schema":{"type":"object","required":[],"properties":{"messages":{"type":"array","description":"The messages to tokenize.","items":{"type":"object","properties":{"content":{"type":"string","description":"Content of the message."},"role":{"type":"string","description":"Role of the message sender.","enum":["system","user","assistant"]}}}},"model":{"type":"string","description":"The model to use for tokenization."},"prompt":{"type":"string","description":"The prompt to tokenize."}}},"example":{"messages":[],"model":"Gemma-4-31B-Lilith-v1.0","prompt":"Hello, world!"}}}}}},"/v1/models":{"get":{"tags":["Models"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/v1/models"},"summary":"List models","description":"Lists the text generation models available to your API key (key-filtered model list, vLLM-compatible).","security":[{"bearerAuth":[]}]}},"/v1/parallel-requests":{"get":{"tags":["Requests"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/v1/parallel-requests"},"summary":"Get parallel request limits","description":"Retrieves the parallel request limits for your account.","security":[{"bearerAuth":[]}]}},"/v1/txt2img":{"post":{"tags":["Images"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/v1/txt2img"},"summary":"Generate image from text","description":"Text-to-image generation.","security":[{"bearerAuth":[]}],"requestBody":{"description":"","required":true,"content":{"application/json":{"schema":{"type":"object","required":[],"properties":{"batch_size":{"type":"number","description":"Number of images to generate in a batch."},"cfg_scale":{"type":"number","description":"Classifier-Free Guidance scale."},"clip_skip":{"type":"number","description":"Number of CLIP layers to skip."},"control_units":{"type":"array","description":"Optional ControlNet-style conditioning units applied on top of the generation (same per-unit fields as control[] on POST /v1/control).","items":{"type":"object","properties":{"adain_weight":{"type":"number","description":"AdaIN weight (Reference units)."},"attention":{"type":"string","description":"Attention mechanism (Reference units).","enum":["Attention","Adain","Attention Adain"]},"end":{"type":"number","description":"Step fraction at which control ends (0.0-1.0)."},"factor":{"type":"number","description":"Conditioning scale factor (T2I-Adapter only)."},"fidelity":{"type":"number","description":"Style fidelity 0.0-1.0 (Reference units)."},"guess":{"type":"boolean","description":"Guess mode (ControlNet only).","enum":[true,false]},"image":{"type":"string","description":"Base64-encoded source image for the unit."},"mode":{"type":"string","description":"Control mode for Union/ProMax models."},"model":{"type":"string","description":"Control model file name for the unit type."},"override":{"type":"string","description":"Base64-encoded pre-computed control map."},"process":{"type":"string","description":"Preprocessor to run on the unit image."},"process_params":{"type":"object","description":"Per-unit preprocessor parameter overrides."},"query_weight":{"type":"number","description":"Attention query weight (Reference units)."},"start":{"type":"number","description":"Step fraction at which control begins (0.0-1.0)."},"strength":{"type":"number","description":"How strongly the control model influences generation (0.0-2.0)."},"unit_type":{"type":"string","description":"Per-unit type override.","enum":["controlnet","t2i adapter","xs","lite","reference"]}}}},"detailer_enabled":{"type":"boolean","description":"Enable the face/detailer refinement pass.","enum":[true,false]},"detailer_model":{"type":"string","description":"Model for the detailer."},"detailer_negative":{"type":"string","description":"Negative prompt for the detailer."},"detailer_prompt":{"type":"string","description":"Prompt for the detailer."},"detailer_steps":{"type":"number","description":"Steps for the detailer."},"detailer_strength":{"type":"number","description":"Strength of the detailer."},"height":{"type":"number","description":"Image height."},"hr_sampler_name":{"type":"string","description":"Sampler name for high-res fix."},"init_control":{"type":"array","description":"Base64-encoded control input image(s) kept separate from the init image(s).","items":{"type":"string"}},"ip_adapter":{"type":"array","description":"Image-prompt conditioning: list of {adapter, images (array of base64), scale, crop, start, end}. Requires a model with supportsIPAdapter.","items":{"type":"object","properties":{"adapter":{"type":"string","description":"IP-Adapter model name."},"crop":{"type":"boolean","description":"Crop option for the unit.","enum":[true,false]},"end":{"type":"number","description":"Step fraction at which conditioning ends (0.0-1.0)."},"images":{"type":"array","description":"Base64-encoded input images."},"scale":{"type":"number","description":"Conditioning scale."},"start":{"type":"number","description":"Step fraction at which conditioning begins (0.0-1.0)."}}}},"negative_prompt":{"type":"string","description":"The negative prompt."},"prompt":{"type":"string","description":"The text prompt.","required":true},"sampler_name":{"type":"string","description":"Sampling method. List via GET /v1/img-samplers."},"sd_model_checkpoint":{"type":"string","description":"The name of the model checkpoint.","required":true},"seed":{"type":"number","description":"Random seed."},"steps":{"type":"number","description":"Number of sampling steps."},"stream":{"type":"boolean","description":"Whether to stream the response.","enum":[true,false]},"width":{"type":"number","description":"Image width."}}},"example":{"batch_size":1,"cfg_scale":6,"clip_skip":2,"control_units":[],"detailer_enabled":"","detailer_model":"","detailer_negative":"","detailer_prompt":"","detailer_steps":"","detailer_strength":"","height":1024,"hr_sampler_name":"","init_control":[],"ip_adapter":[],"negative_prompt":"blurry, low quality","prompt":"A beautiful landscape painting","sampler_name":"Euler a","sd_model_checkpoint":"MODEL_NAME","seed":-1,"steps":20,"stream":"","width":1024}}}}}},"/v1/img2img":{"post":{"tags":["Images"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/v1/img2img"},"summary":"Generate image from image","description":"Image-to-image generation with optional inpainting mask and detailer refinement.","security":[{"bearerAuth":[]}],"requestBody":{"description":"","required":true,"content":{"application/json":{"schema":{"type":"object","required":[],"properties":{"batch_size":{"type":"number","description":"Number of images to generate in a batch."},"cfg_scale":{"type":"number","description":"Classifier-Free Guidance scale."},"clip_skip":{"type":"number","description":"Number of CLIP layers to skip."},"control_units":{"type":"array","description":"Optional ControlNet-style conditioning units applied on top of the generation (same per-unit fields as control[] on POST /v1/control).","items":{"type":"object","properties":{"adain_weight":{"type":"number","description":"AdaIN weight (Reference units)."},"attention":{"type":"string","description":"Attention mechanism (Reference units).","enum":["Attention","Adain","Attention Adain"]},"end":{"type":"number","description":"Step fraction at which control ends (0.0-1.0)."},"factor":{"type":"number","description":"Conditioning scale factor (T2I-Adapter only)."},"fidelity":{"type":"number","description":"Style fidelity 0.0-1.0 (Reference units)."},"guess":{"type":"boolean","description":"Guess mode (ControlNet only).","enum":[true,false]},"image":{"type":"string","description":"Base64-encoded source image for the unit."},"mode":{"type":"string","description":"Control mode for Union/ProMax models."},"model":{"type":"string","description":"Control model file name for the unit type."},"override":{"type":"string","description":"Base64-encoded pre-computed control map."},"process":{"type":"string","description":"Preprocessor to run on the unit image."},"process_params":{"type":"object","description":"Per-unit preprocessor parameter overrides."},"query_weight":{"type":"number","description":"Attention query weight (Reference units)."},"start":{"type":"number","description":"Step fraction at which control begins (0.0-1.0)."},"strength":{"type":"number","description":"How strongly the control model influences generation (0.0-2.0)."},"unit_type":{"type":"string","description":"Per-unit type override.","enum":["controlnet","t2i adapter","xs","lite","reference"]}}}},"denoising_strength":{"type":"number","description":"Denoising strength for img2img."},"detailer_enabled":{"type":"boolean","description":"Enable the face/detailer refinement pass.","enum":[true,false]},"detailer_model":{"type":"string","description":"Model for the detailer."},"detailer_negative":{"type":"string","description":"Negative prompt for the detailer."},"detailer_prompt":{"type":"string","description":"Prompt for the detailer."},"detailer_steps":{"type":"number","description":"Steps for the detailer."},"detailer_strength":{"type":"number","description":"Strength of the detailer."},"height":{"type":"number","description":"Image height."},"init_control":{"type":"array","description":"Base64-encoded control input image(s) kept separate from the init image(s).","items":{"type":"string"}},"init_images":{"type":"array","description":"Base64-encoded initial images.","required":true,"items":{"type":"string"}},"initial_noise_multiplier":{"type":"number","description":"Initial noise multiplier."},"inpaint_full_res":{"type":"boolean","description":"Whether to inpaint at full resolution.","enum":[true,false]},"inpaint_full_res_padding":{"type":"number","description":"Padding for full-resolution inpainting."},"inpainting_fill":{"type":"number","description":"Inpainting fill mode."},"inpainting_mask_invert":{"type":"number","description":"Whether to invert the inpainting mask."},"ip_adapter":{"type":"array","description":"Image-prompt conditioning: list of {adapter, images (array of base64), scale, crop, start, end}. Requires a model with supportsIPAdapter.","items":{"type":"object","properties":{"adapter":{"type":"string","description":"IP-Adapter model name."},"crop":{"type":"boolean","description":"Crop option for the unit.","enum":[true,false]},"end":{"type":"number","description":"Step fraction at which conditioning ends (0.0-1.0)."},"images":{"type":"array","description":"Base64-encoded input images."},"scale":{"type":"number","description":"Conditioning scale."},"start":{"type":"number","description":"Step fraction at which conditioning begins (0.0-1.0)."}}}},"mask":{"type":"string","description":"Base64-encoded mask for inpainting."},"mask_blur":{"type":"number","description":"Mask blur for inpainting."},"negative_prompt":{"type":"string","description":"The negative prompt."},"prompt":{"type":"string","description":"The text prompt.","required":true},"sampler_name":{"type":"string","description":"Sampling method. List via GET /v1/img-samplers."},"sd_model_checkpoint":{"type":"string","description":"The name of the model checkpoint.","required":true},"seed":{"type":"number","description":"Random seed."},"steps":{"type":"number","description":"Number of sampling steps."},"stream":{"type":"boolean","description":"Whether to stream the response.","enum":[true,false]},"width":{"type":"number","description":"Image width."}}},"example":{"batch_size":1,"cfg_scale":6,"clip_skip":2,"control_units":[],"denoising_strength":0.75,"detailer_enabled":"","detailer_model":"","detailer_negative":"","detailer_prompt":"","detailer_steps":"","detailer_strength":"","height":1024,"init_control":[],"init_images":["base64_encoded_image"],"initial_noise_multiplier":"","inpaint_full_res":"","inpaint_full_res_padding":"","inpainting_fill":"","inpainting_mask_invert":"","ip_adapter":[],"mask":"","mask_blur":"","negative_prompt":"blurry, low quality","prompt":"A beautiful landscape painting","sampler_name":"Euler a","sd_model_checkpoint":"MODEL_NAME","seed":-1,"steps":20,"stream":"","width":1024}}}}}},"/v1/upscale-img":{"post":{"tags":["Upscaling"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/v1/upscale-img"},"summary":"Upscale image","description":"Upscales a single image.","security":[{"bearerAuth":[]}],"requestBody":{"description":"","required":true,"content":{"application/json":{"schema":{"type":"object","required":[],"properties":{"image":{"type":"string","description":"The base64-encoded image to upscale.","required":true},"resize_mode":{"type":"number","description":"The resize mode."},"upscaler_1":{"type":"string","description":"The name of the upscaler to use. List via GET /v1/upscalers."},"upscaling_resize":{"type":"number","description":"The factor by which to resize the image."}}},"example":{"image":"","resize_mode":"","upscaler_1":"Lanczos","upscaling_resize":2}}}}}},"/v1/img-options":{"get":{"tags":["Images"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/v1/img-options"},"summary":"Get image generation options","description":"Retrieves image generation options.","security":[{"bearerAuth":[]}]}},"/v1/img-samplers":{"get":{"tags":["Images"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/v1/img-samplers"},"summary":"Get image samplers","description":"Retrieves available image samplers.","security":[{"bearerAuth":[]}]}},"/v1/upscalers":{"get":{"tags":["Upscaling"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/v1/upscalers"},"summary":"Get upscalers","description":"Retrieves available upscalers.","security":[{"bearerAuth":[]}]}},"/v1/control":{"post":{"tags":["Control"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/v1/control"},"summary":"Control-guided image generation","description":"ControlNet-guided generation: generate an image conditioned by one or more control units (ControlNet, T2I-Adapter, ControlNet-XS, ControlLLLite, Reference). Response includes images (base64 outputs), processed (preprocessed control maps), and info.","security":[{"bearerAuth":[]}],"requestBody":{"description":"","required":true,"content":{"application/json":{"schema":{"type":"object","required":[],"properties":{"batch_size":{"type":"number","description":"Number of images to generate in a batch."},"cfg_scale":{"type":"number","description":"Classifier-Free Guidance scale."},"control":{"type":"array","description":"List of control units. At least one enabled unit with an image is required.","required":true,"items":{"type":"object","properties":{"adain_weight":{"type":"number","description":"AdaIN weight (Reference units). Default 1.0."},"attention":{"type":"string","description":"Attention mechanism: Attention, Adain, or Attention Adain (Reference units).","enum":["Attention","Adain","Attention Adain"]},"end":{"type":"number","description":"Step fraction at which control ends (0.0-1.0). Default 1.0."},"factor":{"type":"number","description":"Conditioning scale factor (T2I-Adapter only). Default 1.0."},"fidelity":{"type":"number","description":"Style fidelity 0.0-1.0 (Reference units). Default 0.5."},"guess":{"type":"boolean","description":"Guess mode: remove the need for a prompt (ControlNet only).","enum":[true,false]},"image":{"type":"string","description":"Base64-encoded source image for the unit. When a process is set, the server preprocesses it once; otherwise it is used as the control map directly."},"mode":{"type":"string","description":"Control mode for Union/ProMax models. List valid modes via GET /v1/control-modes."},"model":{"type":"string","description":"Control model file name for the unit type (e.g. Canny XL, OpenPose XL). List via GET /v1/control-models."},"override":{"type":"string","description":"Base64-encoded pre-computed control map that bypasses the preprocessor. Takes priority over image."},"process":{"type":"string","description":"Preprocessor to run on the unit image (e.g. Canny, OpenPose, Depth Anything). Empty/None uses the image as-is. List via GET /v1/preprocessors."},"process_params":{"type":"object","description":"Per-unit preprocessor parameter overrides, e.g. {\"low_threshold\": 50, \"high_threshold\": 150} for Canny."},"query_weight":{"type":"number","description":"Attention query weight (Reference units). Default 1.0."},"start":{"type":"number","description":"Step fraction at which control begins (0.0-1.0). Default 0.0."},"strength":{"type":"number","description":"How strongly the control model influences generation (0.0-2.0). Default 1.0."},"unit_type":{"type":"string","description":"Per-unit type override: controlnet, t2i adapter, xs, lite, or reference. Defaults to the request-level unit_type.","enum":["controlnet","t2i adapter","xs","lite","reference"]}}}},"denoising_strength":{"type":"number","description":"Denoising strength when editing an init image."},"detailer_enabled":{"type":"boolean","description":"Enable the face/detailer refinement pass.","enum":[true,false]},"detailer_prompt":{"type":"string","description":"Prompt for the detailer."},"height_after":{"type":"number","description":"Post-generation resolution height."},"height_before":{"type":"number","description":"Initial/control image resolution height. Defaults to the control image size."},"height_mask":{"type":"number","description":"Mask resolution height."},"init_control":{"type":"array","description":"Base64-encoded init image(s) when input_type is 1 or 2.","items":{"type":"string"}},"input_type":{"type":"number","description":"0 = control only, 1 = init image same as the first control image, 2 = separate init image. Default 0."},"ip_adapter":{"type":"array","description":"Image-prompt conditioning: list of {adapter, images (array of base64), scale, crop, start, end}. Requires supportsIpAdapter model.","items":{"type":"object","properties":{"adapter":{"type":"string","description":"IP-Adapter model name."},"crop":{"type":"boolean","description":"Crop option for the unit.","enum":[true,false]},"end":{"type":"number","description":"Step fraction at which conditioning ends (0.0-1.0)."},"images":{"type":"array","description":"Base64-encoded input images."},"scale":{"type":"number","description":"Conditioning scale."},"start":{"type":"number","description":"Step fraction at which conditioning begins (0.0-1.0)."}}}},"mask":{"type":"string","description":"Base64-encoded mask for inpaint-style edits."},"negative_prompt":{"type":"string","description":"The negative prompt."},"prompt":{"type":"string","description":"The text prompt.","required":true},"sampler_name":{"type":"string","description":"Sampling method."},"sd_model_checkpoint":{"type":"string","description":"The name of the model checkpoint (must support ControlNet generation).","required":true},"seed":{"type":"number","description":"Random seed (-1 = random)."},"steps":{"type":"number","description":"Number of sampling steps (max 40)."},"unit_type":{"type":"string","description":"Control unit family used by units that don't set their own.","enum":["controlnet","t2i adapter","xs","lite","reference"]},"width_after":{"type":"number","description":"Post-generation resolution width."},"width_before":{"type":"number","description":"Initial/control image resolution width. Defaults to the control image size."},"width_mask":{"type":"number","description":"Mask resolution width."}}},"example":{"batch_size":1,"cfg_scale":6,"control":[],"denoising_strength":0.75,"detailer_enabled":"","detailer_prompt":"","height_after":"","height_before":1024,"height_mask":"","init_control":[],"input_type":"","ip_adapter":[],"mask":"","negative_prompt":"blurry, low quality","prompt":"a person standing in front of an ancient castle, dramatic lighting","sampler_name":"Euler a","sd_model_checkpoint":"MODEL_NAME","seed":-1,"steps":20,"unit_type":"controlnet","width_after":"","width_before":1024,"width_mask":""}}}}}},"/v1/preprocess":{"post":{"tags":["Preprocessing"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/v1/preprocess"},"summary":"Preprocess control map","description":"Runs a single control preprocessor on a raw image and returns the resulting control map.","security":[{"bearerAuth":[]}],"requestBody":{"description":"","required":true,"content":{"application/json":{"schema":{"type":"object","required":[],"properties":{"params":{"type":"object","description":"Preprocessor parameter overrides, e.g. {\"low_threshold\": 50, \"high_threshold\": 150} for Canny. Keys must match the preprocessor config.","properties":{}},"image":{"type":"string","description":"Base64-encoded input image to preprocess.","required":true},"model":{"type":"string","description":"Preprocessor name (e.g. Canny, OpenPose, Depth Anything, MLSD). List available names via GET /v1/preprocessors.","required":true}}},"example":{"params":{},"image":"","model":"Canny"}}}}}},"/v1/preprocessors":{"get":{"tags":["Preprocessing"],"parameters":[{"name":"model","in":"query","description":"Selected checkpoint to scope the preprocessor list to. Optional.","required":false,"schema":{"type":"string","example":""}}],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/v1/preprocessors"},"summary":"List preprocessors","description":"Lists available control preprocessors (name, group, and their configurable parameters).","security":[{"bearerAuth":[]}]}},"/v1/control-models":{"get":{"tags":["Control"],"parameters":[{"name":"model","in":"query","description":"Selected checkpoint; optional — defaults to the server's loaded checkpoint.","required":false,"schema":{"type":"string","example":""}},{"name":"unit_type","in":"query","description":"Control unit type.","required":false,"schema":{"type":"string","example":"","items":{"type":"string","enum":["controlnet","t2i adapter","xs","lite","reference"]}}}],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/v1/control-models"},"summary":"List control models","description":"Lists control models for a control unit type.","security":[{"bearerAuth":[]}]}},"/v1/control-modes":{"get":{"tags":["Control"],"parameters":[{"name":"model","in":"query","description":"Selected checkpoint to scope the control modes to. Optional.","required":false,"schema":{"type":"string","example":""}}],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/v1/control-modes"},"summary":"List control modes","description":"Lists the control modes (Union/ProMax predefines) available for the selected checkpoint. Returns a map of control model name to available modes.","security":[{"bearerAuth":[]}]}},"/v1/ip-adapters":{"get":{"tags":["Control"],"parameters":[{"name":"model","in":"query","description":"Selected checkpoint to resolve IP-Adapter availability for; optional — the server falls back to its loaded checkpoint.","required":false,"schema":{"type":"string","example":""}}],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/v1/ip-adapters"},"summary":"List IP adapters","description":"Lists IP-Adapter models available for the selected checkpoint.","security":[{"bearerAuth":[]}]}},"/v1/caption":{"post":{"tags":["Captions"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/v1/caption"},"summary":"Caption image","description":"Generates a descriptive prompt (OpenCLIP/BLIP) from an image.","security":[{"bearerAuth":[]}],"requestBody":{"description":"","required":true,"content":{"application/json":{"schema":{"type":"object","required":[],"properties":{"analyze":{"type":"boolean","description":"When true, also returns medium, artist, movement, trending, and flavor.","enum":[true,false]},"image":{"type":"string","description":"The base64-encoded image to generate a caption from.","required":true},"mode":{"type":"string","description":"Caption mode.","enum":["best","fast","classic","caption","negative"]},"model":{"type":"string","description":"The caption model to use (available via GET /v1/caption/models).","required":true}}},"example":{"analyze":"","image":"","mode":"best","model":"MODEL_NAME"}}}}}},"/v1/caption/models":{"get":{"tags":["Captions"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/v1/caption/models"},"summary":"List caption models","description":"Retrieves the caption models available to your account.","security":[{"bearerAuth":[]}]}},"/v1/tagger":{"post":{"tags":["Tagging"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/v1/tagger"},"summary":"Tag image","description":"Generates booru-style tags (WaifuDiffusion/DeepBooru) for an image.","security":[{"bearerAuth":[]}],"requestBody":{"description":"","required":true,"content":{"application/json":{"schema":{"type":"object","required":[],"properties":{"character_threshold":{"type":"number","description":"Minimum character confidence to include a tag (default 0.85)."},"escape_brackets":{"type":"boolean","description":"Escape brackets so tags are prompt-safe (default true).","enum":[true,false]},"exclude_tags":{"type":"string","description":"Comma-separated tags to always exclude."},"image":{"type":"string","description":"The base64-encoded image to tag.","required":true},"include_rating":{"type":"boolean","description":"Include rating tags (general, sensitive, questionable, explicit).","enum":[true,false]},"max_tags":{"type":"number","description":"Maximum number of tags to return (default 74)."},"model":{"type":"string","description":"The tagger model to use (available via GET /v1/tagger/models).","required":true},"show_scores":{"type":"boolean","description":"Include per-tag confidence scores in the response.","enum":[true,false]},"sort_alpha":{"type":"boolean","description":"Sort tags alphabetically instead of by confidence.","enum":[true,false]},"threshold":{"type":"number","description":"Minimum general confidence to include a tag (default 0.50)."},"use_spaces":{"type":"boolean","description":"Use spaces instead of underscores between words.","enum":[true,false]}}},"example":{"character_threshold":0.85,"escape_brackets":true,"exclude_tags":"ugly, bad anatomy","image":"","include_rating":"","max_tags":74,"model":"MODEL_NAME","show_scores":"","sort_alpha":"","threshold":0.5,"use_spaces":""}}}}}},"/v1/tagger/models":{"get":{"tags":["Tagging"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/v1/tagger/models"},"summary":"List tagger models","description":"Retrieves the tagger models available to your account.","security":[{"bearerAuth":[]}]}},"/model/all":{"get":{"tags":["Status"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/model/all"},"summary":"List models with live status","description":"Returns the full list of available text-generation models, each with a live status (availability) boolean plus cached performance and usage statistics. Public endpoint, no API key required.","security":[{"bearerAuth":[]}]}},"/model/busyness/live":{"get":{"tags":["Status"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/model/busyness/live"},"summary":"Get live model busyness","description":"Returns the current live server busyness percentage for every base model group, keyed by base model name. Public endpoint, no API key required.","security":[{"bearerAuth":[]}]}},"/sdapi/v1/txt2img":{"post":{"tags":["SD Compat"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/sdapi/v1/txt2img"},"summary":"Generate image from text (SD API)","description":"SD-API compatible text-to-image generation. Shares the same parameters as POST /v1/txt2img.","security":[{"bearerAuth":[]}],"requestBody":{"description":"","required":true,"content":{"application/json":{"schema":{"type":"object","required":[],"properties":{"batch_size":{"type":"number","description":"Number of images to generate in a batch."},"cfg_scale":{"type":"number","description":"Classifier-Free Guidance scale."},"clip_skip":{"type":"number","description":"Number of CLIP layers to skip."},"control_units":{"type":"array","description":"Optional ControlNet-style conditioning units applied on top of the generation (same per-unit fields as control[] on POST /v1/control).","items":{"type":"object","properties":{"adain_weight":{"type":"number","description":"AdaIN weight (Reference units)."},"attention":{"type":"string","description":"Attention mechanism (Reference units).","enum":["Attention","Adain","Attention Adain"]},"end":{"type":"number","description":"Step fraction at which control ends (0.0-1.0)."},"factor":{"type":"number","description":"Conditioning scale factor (T2I-Adapter only)."},"fidelity":{"type":"number","description":"Style fidelity 0.0-1.0 (Reference units)."},"guess":{"type":"boolean","description":"Guess mode (ControlNet only).","enum":[true,false]},"image":{"type":"string","description":"Base64-encoded source image for the unit."},"mode":{"type":"string","description":"Control mode for Union/ProMax models."},"model":{"type":"string","description":"Control model file name for the unit type."},"override":{"type":"string","description":"Base64-encoded pre-computed control map."},"process":{"type":"string","description":"Preprocessor to run on the unit image."},"process_params":{"type":"object","description":"Per-unit preprocessor parameter overrides."},"query_weight":{"type":"number","description":"Attention query weight (Reference units)."},"start":{"type":"number","description":"Step fraction at which control begins (0.0-1.0)."},"strength":{"type":"number","description":"How strongly the control model influences generation (0.0-2.0)."},"unit_type":{"type":"string","description":"Per-unit type override.","enum":["controlnet","t2i adapter","xs","lite","reference"]}}}},"detailer_enabled":{"type":"boolean","description":"Enable the face/detailer refinement pass.","enum":[true,false]},"detailer_model":{"type":"string","description":"Model for the detailer."},"detailer_negative":{"type":"string","description":"Negative prompt for the detailer."},"detailer_prompt":{"type":"string","description":"Prompt for the detailer."},"detailer_steps":{"type":"number","description":"Steps for the detailer."},"detailer_strength":{"type":"number","description":"Strength of the detailer."},"height":{"type":"number","description":"Image height."},"hr_sampler_name":{"type":"string","description":"Sampler name for high-res fix."},"init_control":{"type":"array","description":"Base64-encoded control input image(s) kept separate from the init image(s).","items":{"type":"string"}},"ip_adapter":{"type":"array","description":"Image-prompt conditioning: list of {adapter, images (array of base64), scale, crop, start, end}. Requires a model with supportsIPAdapter.","items":{"type":"object","properties":{"adapter":{"type":"string","description":"IP-Adapter model name."},"crop":{"type":"boolean","description":"Crop option for the unit.","enum":[true,false]},"end":{"type":"number","description":"Step fraction at which conditioning ends (0.0-1.0)."},"images":{"type":"array","description":"Base64-encoded input images."},"scale":{"type":"number","description":"Conditioning scale."},"start":{"type":"number","description":"Step fraction at which conditioning begins (0.0-1.0)."}}}},"negative_prompt":{"type":"string","description":"The negative prompt."},"prompt":{"type":"string","description":"The text prompt.","required":true},"sampler_name":{"type":"string","description":"Sampling method. List via GET /v1/img-samplers."},"sd_model_checkpoint":{"type":"string","description":"The name of the model checkpoint.","required":true},"seed":{"type":"number","description":"Random seed."},"steps":{"type":"number","description":"Number of sampling steps."},"stream":{"type":"boolean","description":"Whether to stream the response.","enum":[true,false]},"width":{"type":"number","description":"Image width."}}},"example":{"batch_size":1,"cfg_scale":6,"clip_skip":2,"control_units":[],"detailer_enabled":"","detailer_model":"","detailer_negative":"","detailer_prompt":"","detailer_steps":"","detailer_strength":"","height":1024,"hr_sampler_name":"","init_control":[],"ip_adapter":[],"negative_prompt":"blurry, low quality","prompt":"A beautiful landscape painting","sampler_name":"Euler a","sd_model_checkpoint":"MODEL_NAME","seed":-1,"steps":20,"stream":"","width":1024}}}}}},"/sdapi/v1/img2img":{"post":{"tags":["SD Compat"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/sdapi/v1/img2img"},"summary":"Generate image from image (SD API)","description":"SD-API compatible image-to-image generation. Shares the same parameters as POST /v1/img2img.","security":[{"bearerAuth":[]}],"requestBody":{"description":"","required":true,"content":{"application/json":{"schema":{"type":"object","required":[],"properties":{"batch_size":{"type":"number","description":"Number of images to generate in a batch."},"cfg_scale":{"type":"number","description":"Classifier-Free Guidance scale."},"clip_skip":{"type":"number","description":"Number of CLIP layers to skip."},"control_units":{"type":"array","description":"Optional ControlNet-style conditioning units applied on top of the generation (same per-unit fields as control[] on POST /v1/control).","items":{"type":"object","properties":{"adain_weight":{"type":"number","description":"AdaIN weight (Reference units)."},"attention":{"type":"string","description":"Attention mechanism (Reference units).","enum":["Attention","Adain","Attention Adain"]},"end":{"type":"number","description":"Step fraction at which control ends (0.0-1.0)."},"factor":{"type":"number","description":"Conditioning scale factor (T2I-Adapter only)."},"fidelity":{"type":"number","description":"Style fidelity 0.0-1.0 (Reference units)."},"guess":{"type":"boolean","description":"Guess mode (ControlNet only).","enum":[true,false]},"image":{"type":"string","description":"Base64-encoded source image for the unit."},"mode":{"type":"string","description":"Control mode for Union/ProMax models."},"model":{"type":"string","description":"Control model file name for the unit type."},"override":{"type":"string","description":"Base64-encoded pre-computed control map."},"process":{"type":"string","description":"Preprocessor to run on the unit image."},"process_params":{"type":"object","description":"Per-unit preprocessor parameter overrides."},"query_weight":{"type":"number","description":"Attention query weight (Reference units)."},"start":{"type":"number","description":"Step fraction at which control begins (0.0-1.0)."},"strength":{"type":"number","description":"How strongly the control model influences generation (0.0-2.0)."},"unit_type":{"type":"string","description":"Per-unit type override.","enum":["controlnet","t2i adapter","xs","lite","reference"]}}}},"denoising_strength":{"type":"number","description":"Denoising strength for img2img."},"detailer_enabled":{"type":"boolean","description":"Enable the face/detailer refinement pass.","enum":[true,false]},"detailer_model":{"type":"string","description":"Model for the detailer."},"detailer_negative":{"type":"string","description":"Negative prompt for the detailer."},"detailer_prompt":{"type":"string","description":"Prompt for the detailer."},"detailer_steps":{"type":"number","description":"Steps for the detailer."},"detailer_strength":{"type":"number","description":"Strength of the detailer."},"height":{"type":"number","description":"Image height."},"init_control":{"type":"array","description":"Base64-encoded control input image(s) kept separate from the init image(s).","items":{"type":"string"}},"init_images":{"type":"array","description":"Base64-encoded initial images.","required":true,"items":{"type":"string"}},"initial_noise_multiplier":{"type":"number","description":"Initial noise multiplier."},"inpaint_full_res":{"type":"boolean","description":"Whether to inpaint at full resolution.","enum":[true,false]},"inpaint_full_res_padding":{"type":"number","description":"Padding for full-resolution inpainting."},"inpainting_fill":{"type":"number","description":"Inpainting fill mode."},"inpainting_mask_invert":{"type":"number","description":"Whether to invert the inpainting mask."},"ip_adapter":{"type":"array","description":"Image-prompt conditioning: list of {adapter, images (array of base64), scale, crop, start, end}. Requires a model with supportsIPAdapter.","items":{"type":"object","properties":{"adapter":{"type":"string","description":"IP-Adapter model name."},"crop":{"type":"boolean","description":"Crop option for the unit.","enum":[true,false]},"end":{"type":"number","description":"Step fraction at which conditioning ends (0.0-1.0)."},"images":{"type":"array","description":"Base64-encoded input images."},"scale":{"type":"number","description":"Conditioning scale."},"start":{"type":"number","description":"Step fraction at which conditioning begins (0.0-1.0)."}}}},"mask":{"type":"string","description":"Base64-encoded mask for inpainting."},"mask_blur":{"type":"number","description":"Mask blur for inpainting."},"negative_prompt":{"type":"string","description":"The negative prompt."},"prompt":{"type":"string","description":"The text prompt.","required":true},"sampler_name":{"type":"string","description":"Sampling method. List via GET /v1/img-samplers."},"sd_model_checkpoint":{"type":"string","description":"The name of the model checkpoint.","required":true},"seed":{"type":"number","description":"Random seed."},"steps":{"type":"number","description":"Number of sampling steps."},"stream":{"type":"boolean","description":"Whether to stream the response.","enum":[true,false]},"width":{"type":"number","description":"Image width."}}},"example":{"batch_size":1,"cfg_scale":6,"clip_skip":2,"control_units":[],"denoising_strength":0.75,"detailer_enabled":"","detailer_model":"","detailer_negative":"","detailer_prompt":"","detailer_steps":"","detailer_strength":"","height":1024,"init_control":[],"init_images":["base64_encoded_image"],"initial_noise_multiplier":"","inpaint_full_res":"","inpaint_full_res_padding":"","inpainting_fill":"","inpainting_mask_invert":"","ip_adapter":[],"mask":"","mask_blur":"","negative_prompt":"blurry, low quality","prompt":"A beautiful landscape painting","sampler_name":"Euler a","sd_model_checkpoint":"MODEL_NAME","seed":-1,"steps":20,"stream":"","width":1024}}}}}},"/sdapi/v1/control":{"post":{"tags":["SD Compat"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/sdapi/v1/control"},"summary":"Control-guided image generation (SD API)","description":"SD-API compatible ControlNet-guided generation. Response includes processed (preprocessed control maps) alongside images. Equivalent to POST /v1/control.","security":[{"bearerAuth":[]}],"requestBody":{"description":"","required":true,"content":{"application/json":{"schema":{"type":"object","required":[],"properties":{"batch_size":{"type":"number","description":"Number of images to generate in a batch."},"cfg_scale":{"type":"number","description":"Classifier-Free Guidance scale."},"control":{"type":"array","description":"List of control units. At least one enabled unit with an image is required.","required":true,"items":{"type":"object","properties":{"adain_weight":{"type":"number","description":"AdaIN weight (Reference units). Default 1.0."},"attention":{"type":"string","description":"Attention mechanism: Attention, Adain, or Attention Adain (Reference units).","enum":["Attention","Adain","Attention Adain"]},"end":{"type":"number","description":"Step fraction at which control ends (0.0-1.0). Default 1.0."},"factor":{"type":"number","description":"Conditioning scale factor (T2I-Adapter only). Default 1.0."},"fidelity":{"type":"number","description":"Style fidelity 0.0-1.0 (Reference units). Default 0.5."},"guess":{"type":"boolean","description":"Guess mode: remove the need for a prompt (ControlNet only).","enum":[true,false]},"image":{"type":"string","description":"Base64-encoded source image for the unit. When a process is set, the server preprocesses it once; otherwise it is used as the control map directly."},"mode":{"type":"string","description":"Control mode for Union/ProMax models. List valid modes via GET /v1/control-modes."},"model":{"type":"string","description":"Control model file name for the unit type (e.g. Canny XL, OpenPose XL). List via GET /v1/control-models."},"override":{"type":"string","description":"Base64-encoded pre-computed control map that bypasses the preprocessor. Takes priority over image."},"process":{"type":"string","description":"Preprocessor to run on the unit image (e.g. Canny, OpenPose, Depth Anything). Empty/None uses the image as-is. List via GET /v1/preprocessors."},"process_params":{"type":"object","description":"Per-unit preprocessor parameter overrides, e.g. {\"low_threshold\": 50, \"high_threshold\": 150} for Canny."},"query_weight":{"type":"number","description":"Attention query weight (Reference units). Default 1.0."},"start":{"type":"number","description":"Step fraction at which control begins (0.0-1.0). Default 0.0."},"strength":{"type":"number","description":"How strongly the control model influences generation (0.0-2.0). Default 1.0."},"unit_type":{"type":"string","description":"Per-unit type override: controlnet, t2i adapter, xs, lite, or reference. Defaults to the request-level unit_type.","enum":["controlnet","t2i adapter","xs","lite","reference"]}}}},"denoising_strength":{"type":"number","description":"Denoising strength when editing an init image."},"detailer_enabled":{"type":"boolean","description":"Enable the face/detailer refinement pass.","enum":[true,false]},"detailer_prompt":{"type":"string","description":"Prompt for the detailer."},"height_after":{"type":"number","description":"Post-generation resolution height."},"height_before":{"type":"number","description":"Initial/control image resolution height. Defaults to the control image size."},"height_mask":{"type":"number","description":"Mask resolution height."},"init_control":{"type":"array","description":"Base64-encoded init image(s) when input_type is 1 or 2.","items":{"type":"string"}},"input_type":{"type":"number","description":"0 = control only, 1 = init image same as the first control image, 2 = separate init image. Default 0."},"ip_adapter":{"type":"array","description":"Image-prompt conditioning: list of {adapter, images (array of base64), scale, crop, start, end}. Requires supportsIpAdapter model.","items":{"type":"object","properties":{"adapter":{"type":"string","description":"IP-Adapter model name."},"crop":{"type":"boolean","description":"Crop option for the unit.","enum":[true,false]},"end":{"type":"number","description":"Step fraction at which conditioning ends (0.0-1.0)."},"images":{"type":"array","description":"Base64-encoded input images."},"scale":{"type":"number","description":"Conditioning scale."},"start":{"type":"number","description":"Step fraction at which conditioning begins (0.0-1.0)."}}}},"mask":{"type":"string","description":"Base64-encoded mask for inpaint-style edits."},"negative_prompt":{"type":"string","description":"The negative prompt."},"prompt":{"type":"string","description":"The text prompt.","required":true},"sampler_name":{"type":"string","description":"Sampling method."},"sd_model_checkpoint":{"type":"string","description":"The name of the model checkpoint (must support ControlNet generation).","required":true},"seed":{"type":"number","description":"Random seed (-1 = random)."},"steps":{"type":"number","description":"Number of sampling steps (max 40)."},"unit_type":{"type":"string","description":"Control unit family used by units that don't set their own.","enum":["controlnet","t2i adapter","xs","lite","reference"]},"width_after":{"type":"number","description":"Post-generation resolution width."},"width_before":{"type":"number","description":"Initial/control image resolution width. Defaults to the control image size."},"width_mask":{"type":"number","description":"Mask resolution width."}}},"example":{"batch_size":1,"cfg_scale":6,"control":[],"denoising_strength":0.75,"detailer_enabled":"","detailer_prompt":"","height_after":"","height_before":1024,"height_mask":"","init_control":[],"input_type":"","ip_adapter":[],"mask":"","negative_prompt":"blurry, low quality","prompt":"a person standing in front of an ancient castle, dramatic lighting","sampler_name":"Euler a","sd_model_checkpoint":"MODEL_NAME","seed":-1,"steps":20,"unit_type":"controlnet","width_after":"","width_before":1024,"width_mask":""}}}}}},"/sdapi/v1/preprocess":{"post":{"tags":["SD Compat"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/sdapi/v1/preprocess"},"summary":"Preprocess control map (SD API)","description":"SD-API compatible single-preprocessor run. Equivalent to POST /v1/preprocess.","security":[{"bearerAuth":[]}],"requestBody":{"description":"","required":true,"content":{"application/json":{"schema":{"type":"object","required":[],"properties":{"params":{"type":"object","description":"Preprocessor parameter overrides, e.g. {\"low_threshold\": 50, \"high_threshold\": 150} for Canny.","properties":{}},"image":{"type":"string","description":"Base64-encoded input image to preprocess.","required":true},"model":{"type":"string","description":"Preprocessor name (e.g. Canny, OpenPose, Depth Anything). List available names via GET /sdapi/v1/preprocessors.","required":true}}},"example":{"params":{},"image":"","model":"Canny"}}}}}},"/sdapi/v1/extra-single-image":{"post":{"tags":["SD Compat"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/sdapi/v1/extra-single-image"},"summary":"Upscale image (SD API)","description":"SD-API compatible upscaling. Shares the same parameters as POST /v1/upscale-img.","security":[{"bearerAuth":[]}],"requestBody":{"description":"","required":true,"content":{"application/json":{"schema":{"type":"object","required":[],"properties":{"image":{"type":"string","description":"The base64-encoded image to upscale.","required":true},"resize_mode":{"type":"number","description":"The resize mode."},"upscaler_1":{"type":"string","description":"The name of the upscaler to use."},"upscaling_resize":{"type":"number","description":"The factor by which to resize the image."}}},"example":{"image":"","resize_mode":"","upscaler_1":"R-ESRGAN 4x+","upscaling_resize":2}}}}}},"/sdapi/v1/sd-models":{"get":{"tags":["SD Compat"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/sdapi/v1/sd-models"},"summary":"Get image models (SD API)","description":"Retrieves available image models.","security":[{"bearerAuth":[]}]}},"/sdapi/v1/upscalers":{"get":{"tags":["SD Compat"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/sdapi/v1/upscalers"},"summary":"Get upscalers (SD API)","description":"Retrieves available upscalers.","security":[{"bearerAuth":[]}]}},"/sdapi/v1/options":{"get":{"tags":["SD Compat"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/sdapi/v1/options"},"summary":"Get image generation options (SD API)","description":"Retrieves image generation options.","security":[{"bearerAuth":[]}]}},"/sdapi/v1/samplers":{"get":{"tags":["SD Compat"],"parameters":[],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/sdapi/v1/samplers"},"summary":"Get image samplers (SD API)","description":"Retrieves available image samplers.","security":[{"bearerAuth":[]}]}},"/sdapi/v1/ip-adapters":{"get":{"tags":["SD Compat"],"parameters":[{"name":"model","in":"query","description":"Selected checkpoint to scope the list to. Optional.","required":false,"schema":{"type":"string","example":""}}],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/sdapi/v1/ip-adapters"},"summary":"List IP adapters (SD API)","description":"Lists IP-Adapter models, optionally scoped to the selected checkpoint. Equivalent to GET /v1/ip-adapters.","security":[{"bearerAuth":[]}]}},"/sdapi/v1/control-models":{"get":{"tags":["SD Compat"],"parameters":[{"name":"model","in":"query","description":"Selected checkpoint to scope the list to. Optional.","required":false,"schema":{"type":"string","example":""}},{"name":"unit_type","in":"query","description":"Control unit type.","required":false,"schema":{"type":"string","example":"","items":{"type":"string","enum":["controlnet","t2i adapter","xs","lite","reference"]}}}],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/sdapi/v1/control-models"},"summary":"List control models (SD API)","description":"Lists control models for a control unit type, optionally scoped to the selected checkpoint. Equivalent to GET /v1/control-models.","security":[{"bearerAuth":[]}]}},"/sdapi/v1/preprocessors":{"get":{"tags":["SD Compat"],"parameters":[{"name":"model","in":"query","description":"Selected checkpoint to scope the list to. Optional.","required":false,"schema":{"type":"string","example":""}}],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/sdapi/v1/preprocessors"},"summary":"List preprocessors (SD API)","description":"Lists available control preprocessors with their parameters, optionally scoped via ?model=. Equivalent to GET /v1/preprocessors.","security":[{"bearerAuth":[]}]}},"/sdapi/v1/control-modes":{"get":{"tags":["SD Compat"],"parameters":[{"name":"model","in":"query","description":"Selected checkpoint to scope the list to. Optional.","required":false,"schema":{"type":"string","example":""}}],"responses":{"401":{"description":"Bearer token required (Authorization header)","content":{"application/json":{}}}},"externalDocs":{"api_ref":"https://arliai.com/docs/api","api_endpoint":"https://api.arliai.com/sdapi/v1/control-modes"},"summary":"List control modes (SD API)","description":"Lists control modes (Union/ProMax predefines) for the selected checkpoint. Equivalent to GET /v1/control-modes.","security":[{"bearerAuth":[]}]}}},"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer"}}},"security":[{"bearerAuth":[]}]}