ollama.com APIollama.com ↗
Search Ollama's model library, retrieve model details, and list all tags/variants with context windows, file sizes, and pull commands via 3 REST endpoints.
curl -X GET 'https://api.parse.bot/scraper/f1555b97-c36d-48d9-b657-60146faa21e9/search_models?sort=popular&query=gemma&capability=vision' \ -H 'X-API-Key: $PARSE_API_KEY'
Search for models on Ollama by keyword, with optional capability filters and sorting. Returns a list of matching models with descriptions, capabilities, available sizes, download counts, and pull commands. Combining sort=newest with a capability filter may return fewer results than sort=popular.
| Param | Type | Description |
|---|---|---|
| sort | string | Sort order: 'popular' or 'newest' |
| query | string | Search keyword (e.g., 'deepseek', 'qwen3', 'gemma') |
| capability | string | Filter by capability: 'cloud', 'embedding', 'vision', 'tools', 'thinking'. Empty string means no filter. |
{
"type": "object",
"fields": {
"sort": "string, the sort order used",
"query": "string, the search keyword used",
"models": "array of model objects with name, slug, description, capabilities, sizes, pull_count, tag_count, updated, pull_command",
"total_results": "integer, number of models returned",
"capability_filter": "string, the capability filter applied"
},
"sample": {
"data": {
"sort": "popular",
"query": "deepseek",
"models": [
{
"name": "deepseek-r1",
"slug": "deepseek-r1",
"sizes": [
"1.5b",
"7b",
"8b",
"14b",
"32b",
"70b",
"671b"
],
"updated": "10 months ago",
"tag_count": "35",
"pull_count": "84.2M",
"description": "DeepSeek-R1 is a family of open reasoning models with performance approaching that of leading models.",
"capabilities": [
"tools",
"thinking"
],
"pull_command": "ollama pull deepseek-r1"
}
],
"total_results": 15,
"capability_filter": ""
},
"status": "success"
}
}About the ollama.com API
The Ollama API exposes 3 endpoints for searching and inspecting AI models hosted on ollama.com. search_models returns a filterable list of models including capabilities, parameter sizes, and download counts. get_model_detail returns per-model metadata such as run and pull commands. get_model_tags returns every variant for a given model, including context window length, file size, and hash.
What the API covers
The Ollama API gives programmatic access to the model library at ollama.com. Three endpoints cover the full discovery workflow: searching the catalog, reading per-model metadata, and enumerating every tagged variant. Response fields include capabilities (values like thinking, tools, vision, embedding), formatted download_count, pull_command, run_command, and relative updated timestamps.
Searching and filtering models
search_models accepts a free-text query (e.g. deepseek, qwen3, gemma), an optional capability filter, and a sort parameter of either popular or newest. The response includes a models array where each object carries the model slug, description, sizes (parameter counts like 1.5b, 7b, 70b), tag_count, pull_count, and a ready-to-paste pull_command. Note that combining sort=newest with a capability filter can reduce result counts compared to using either alone.
Model detail and tags
get_model_detail takes a model_name slug and returns the full display title, description, capabilities array, all available sizes, and both pull_command and run_command strings — useful for automating local setup scripts. For finer-grained variant data, get_model_tags returns a tags array where each entry includes the exact tag, full_name, size (on-disk file size), context (context window length), input_type, hash, and pull_command. total_tags gives the count of all variants for that model.
- Build a model selection UI that filters ollama.com models by capability (e.g.
vision,tools) and sorts by popularity - Automate local LLM setup scripts by pulling
pull_commandandrun_commandfromget_model_detail - Compare context window sizes across all variants of a model using
contextfields fromget_model_tags - Track newly published models by polling
search_modelswithsort=newest - Build a model size calculator by aggregating
sizefields fromget_model_tagsto estimate disk requirements - Generate a changelog or catalog of available embedding models by filtering
search_modelswithcapability=embedding - Identify the most-downloaded models in a category using
pull_countfromsearch_modelsresults
| Tier | Price | Credits/month | Rate limit |
|---|---|---|---|
| Free | $0/mo | 100 | 5 req/min |
| Hobby | $30/mo | 1,000 | 20 req/min |
| Developer | $100/mo | 5,000 | 250 req/min |
One credit = one API call regardless of which marketplace API you call. Exceeding the rate limit returns a 429 response. Authenticate with the X-API-Key header.
Does Ollama have an official developer API?+
What does `get_model_tags` return beyond what `get_model_detail` provides?+
get_model_detail returns aggregate metadata: display title, description, all available parameter sizes, total download count, and pull/run commands. get_model_tags goes per-variant: each tag object includes the exact tag string, on-disk size, context window length, input_type, and a hash for integrity checking. Use get_model_tags when you need to differentiate between, for example, a q4_0 and q8_0 quantization of the same model.Are user reviews, community comments, or model benchmark scores available?+
Is there pagination support for `search_models` results?+
total_results count reflecting how many models matched, but there is no page or offset parameter exposed. All matching results for the query are returned in a single response. If you need to paginate across the full catalog, you can fork this API on Parse and revise it to add offset or cursor parameters.Does the `capability` filter in `search_models` affect result counts?+
capability_filter field in the response confirms what filter was applied. Combining sort=newest with a capability filter (e.g. capability=thinking) tends to return fewer results than using sort=popular with the same filter, because not all recently added models carry every capability tag. Omitting the capability field returns the full unfiltered set for the given query and sort.