data
Stability AI CLI for AI Agents
Use the Stability AI CLI from KosmoKrator to call Stability AI tools headlessly, return JSON, inspect schemas, and automate workflows from coding agents, scripts, and CI.Stability AI CLI Setup
Stability AI can be configured headlessly with `kosmokrator integrations:configure stability`.
# Install KosmoKrator first if it is not available on PATH.
curl -fsSL https://raw.githubusercontent.com/OpenCompanyApp/kosmokrator/main/install.sh | bash
# Configure and verify this integration.
kosmokrator integrations:configure stability --enable --read allow --write ask --json
kosmokrator integrations:doctor stability --json
kosmokrator integrations:status --json Credentials
Authentication type: API key api_key. Configure credentials once, then reuse the same stored profile from scripts, coding CLIs, Lua, and MCP.
No credentials are required.
Command Patterns
The generic command is stable across every integration. The provider shortcut is shorter for humans.
kosmo integrations:call stability.stability_get_account '{}' --json kosmo integrations:stability stability_get_account '{}' --json Discovery
These commands return structured output for coding agents that need to inspect capabilities before choosing a function.
kosmo integrations:docs stability --json
kosmo integrations:docs stability.stability_get_account --json
kosmo integrations:schema stability.stability_get_account --json
kosmo integrations:search "Stability AI" --json
kosmo integrations:list --json Automation Contexts
The same configured command surface works in these environments. The command does not change unless the host wrapper, credentials, or permissions change.
CLI Functions
Every function below can be called headlessly. Commands are highlighted, copyable, and scroll horizontally when payloads are long.
stability.stability_get_account
Get the account associated with the Stability AI API key.
read - Parameters
- none
kosmo integrations:call stability.stability_get_account '{}' --json kosmo integrations:stability stability_get_account '{}' --json stability.stability_get_balance
Get credit balance for the Stability AI API key.
read - Parameters
- none
kosmo integrations:call stability.stability_get_balance '{}' --json kosmo integrations:stability stability_get_balance '{}' --json stability.stability_generate_core
Generate an image with Stable Image Core.
write - Parameters
- none
kosmo integrations:call stability.stability_generate_core '{}' --json kosmo integrations:stability stability_generate_core '{}' --json stability.stability_generate_ultra
Generate a high-quality image with Stable Image Ultra.
write - Parameters
- none
kosmo integrations:call stability.stability_generate_ultra '{}' --json kosmo integrations:stability stability_generate_ultra '{}' --json stability.stability_generate_sd3
Generate an image with Stable Diffusion 3 or 3.5 models.
write - Parameters
- none
kosmo integrations:call stability.stability_generate_sd3 '{}' --json kosmo integrations:stability stability_generate_sd3 '{}' --json stability.stability_inpaint
Fill or replace masked areas of an image.
write - Parameters
- none
kosmo integrations:call stability.stability_inpaint '{}' --json kosmo integrations:stability stability_inpaint '{}' --json stability.stability_erase
Remove masked areas from an image.
write - Parameters
- none
kosmo integrations:call stability.stability_erase '{}' --json kosmo integrations:stability stability_erase '{}' --json stability.stability_remove_background
Remove an image background.
write - Parameters
- none
kosmo integrations:call stability.stability_remove_background '{}' --json kosmo integrations:stability stability_remove_background '{}' --json stability.stability_control_structure
Generate an image guided by the structure of an input image.
write - Parameters
- none
kosmo integrations:call stability.stability_control_structure '{}' --json kosmo integrations:stability stability_control_structure '{}' --json stability.stability_upscale_fast
Quickly upscale an image.
write - Parameters
- none
kosmo integrations:call stability.stability_upscale_fast '{}' --json kosmo integrations:stability stability_upscale_fast '{}' --json stability.stability_upscale_creative
Upscale an image with creative enhancement.
write - Parameters
- none
kosmo integrations:call stability.stability_upscale_creative '{}' --json kosmo integrations:stability stability_upscale_creative '{}' --json stability.stability_image_to_video
Start an image-to-video generation job.
write - Parameters
- none
kosmo integrations:call stability.stability_image_to_video '{}' --json kosmo integrations:stability stability_image_to_video '{}' --json stability.stability_get_video_result
Fetch the result of an image-to-video generation job.
read - Parameters
- none
kosmo integrations:call stability.stability_get_video_result '{}' --json kosmo integrations:stability stability_get_video_result '{}' --json Function Schemas
Use these parameter tables when building CLI payloads without calling integrations:schema first.
stability.stability_get_account 0 parameters
kosmo integrations:schema stability.stability_get_account --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
stability.stability_get_balance 0 parameters
kosmo integrations:schema stability.stability_get_balance --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
stability.stability_generate_core 0 parameters
kosmo integrations:schema stability.stability_generate_core --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
stability.stability_generate_ultra 0 parameters
kosmo integrations:schema stability.stability_generate_ultra --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
stability.stability_generate_sd3 0 parameters
kosmo integrations:schema stability.stability_generate_sd3 --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
stability.stability_inpaint 0 parameters
kosmo integrations:schema stability.stability_inpaint --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
stability.stability_erase 0 parameters
kosmo integrations:schema stability.stability_erase --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
stability.stability_remove_background 0 parameters
kosmo integrations:schema stability.stability_remove_background --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
stability.stability_control_structure 0 parameters
kosmo integrations:schema stability.stability_control_structure --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
stability.stability_upscale_fast 0 parameters
kosmo integrations:schema stability.stability_upscale_fast --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
stability.stability_upscale_creative 0 parameters
kosmo integrations:schema stability.stability_upscale_creative --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
stability.stability_image_to_video 0 parameters
kosmo integrations:schema stability.stability_image_to_video --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
stability.stability_get_video_result 0 parameters
kosmo integrations:schema stability.stability_get_video_result --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
Permissions
Headless calls still follow the integration read/write permission policy. Configure read/write defaults with
integrations:configure. Add --force only for trusted automation that should bypass that policy.