{"type":"api","title":"List available LLM models","meta":{"id":"/apps/pubhub/media/crosswork-ai-api-v1/f1588771b7d7f6c4ce17ce8969907cd492624572/reference/758eddac-527a-34c4-a528-aa0ac612147f","info":{"title":"Crosswork AI - LLM","description":"Subset of the Crosswork AI API that covers LLM provider, model, association,\ndefault LLM, OAuth2 configuration, and connectivity check operations.\n","version":"1.0.0","contact":{"name":"Crosswork AI Team","url":"https://developer.cisco.com"},"license":{"name":"Cisco Proprietary","url":"https://www.cisco.com/go/terms"}},"tags":[{"name":"LLM","description":"Operations related to LLM providers and models"}],"x-parser-conf":{"overview":{"markdownPath":"llm/overview.md"}},"openapi":"3.1.0","servers":[{"url":"https://{host}","description":"Crosswork AI gateway"}]},"spec":{"tags":["LLM"],"summary":"List available LLM models","description":"Retrieves a list of all available LLM models from configured providers.\nUses LiteLLM's model discovery to fetch models dynamically.\n","operationId":"getLLMModelsList","parameters":[{"name":"provider","in":"query","required":false,"schema":{"type":"string"},"description":"Filter models by provider name (e.g., openai, anthropic)"}],"responses":{"200":{"description":"Models listed successfully","content":{"application/json":{"schema":{"type":"object","required":["models"],"properties":{"models":{"type":"array","items":{"type":"object","required":["id","name","provider"],"properties":{"id":{"type":"string","description":"The model identifier","example":"d83c663c-315c-42d7-9738-ab2832b1adf7"},"model":{"type":"string","description":"The model name including provider (e.g., \"openai/gpt-4\", \"anthropic/claude-3-opus\", \"ollama/llama3\")","example":"ollama/llama3"},"name":{"type":"string","description":"The model name","example":"ollama/llama3"},"api_base":{"type":"string","description":"API base URL for the model provider","example":"https://api.openai.com"},"api_version":{"type":"string","description":"The model api version, if applicable (e.g., \"2024-06-01\" for Azure OpenAI)","example":"2024-06-01"},"provider":{"type":"string","description":"The model provider","example":"openai"},"is_custom_provider":{"type":"boolean","description":"Indicates whether this model is from a custom provider","example":false},"key":{"type":"string","description":"The model key","example":"openai-gpt-4"},"max_tokens":{"type":"integer","description":"Maximum total tokens (input + output)","example":8192},"max_input_tokens":{"type":"integer","description":"Maximum input tokens","example":6144},"max_output_tokens":{"type":"integer","description":"Maximum output tokens","example":2048},"input_cost_per_token":{"type":"number","format":"double","description":"Cost per input token in USD","example":0.00003},"output_cost_per_token":{"type":"number","format":"double","description":"Cost per output token in USD","example":0.00006},"supports_function_calling":{"type":"boolean","description":"Whether the model supports function calling"},"supports_vision":{"type":"boolean","description":"Whether the model supports vision/image inputs"},"mode":{"type":"string","description":"Model mode (e.g., chat, completion)"}},"$$ref":"#/components/schemas/LLMModel"},"description":"List of available models"}},"$$ref":"#/components/schemas/LLMModelList"}}}},"400":{"description":"Invalid request parameters","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string","description":"Error message"}}}}}},"404":{"description":"Provider not found","content":{"application/json":{"schema":{"description":"Represents error object","type":"object","properties":{"code":{"type":"integer","format":"int64"},"message":{"type":"string"}},"required":["code","message"],"$$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"description":"Represents error object","type":"object","properties":{"code":{"type":"integer","format":"int64"},"message":{"type":"string"}},"required":["code","message"],"$$ref":"#/components/schemas/Error"}}}}},"method":"get","path":"/api/v1/llm/models"}}