Hugging Face API: Get model details
Looks up one Hugging Face model by name, repository ID or link and returns its public details, model card summary and file sizes. For a name, the first matching model is returned.
Unofficial. Not affiliated with or endorsed by Hugging Face.
Inputs
Values from the run on Oct 23, 2026, shown under Output.
- Model, required
model Model name, repository name, or Hugging Face model link, for example Llama 3.1 8B Instruct or meta-llama/Llama-3.1-8B-Instruct.
Llama 3.1 8B Instruct
Input as JSON
{ "model": "Llama 3.1 8B Instruct"}Output
{ "task": "Text generation", "files": [ { "name": ".gitattributes", "size_bytes": 1519 }, { "name": "LICENSE", "size_bytes": 7627 }, { "name": "README.md", "size_bytes": 44044 } ], "gated": true, "likes": 8563, "author": "meta-llama", "license": "Llama 3.1", "languages": [ "en", "de", "fr" ], "base_model": "meta-llama/Meta-Llama-3.1-8B" , "model_name": "Llama-3.1-8B-Instruct", "datasets_used": [], "matched_model": "Llama-3.1-8B-Instruct by meta-llama", "repository_id": "meta-llama/Llama-3.1-8B-Instruct" , "model_page_link": "https://huggingface.co/meta-llama/Llama-3.1-8B-Instruct" , "parameter_count": 8030261248, "last_updated_date": "2024-09-25", "model_card_summary": "The Meta Llama 3.1 collection of multilingual large language models (LLMs) is a collection of pretrained and instruction tuned generative models in 8B, 70B and 405B sizes (text in/text out). The Llama 3.1 instruction tuned text only models (8B, 70B, 405B) are optimized for multilingual dialogue use …" , "downloads_last_30_days": 4864172}Code
curl https://api.fous.com/v1/runs \ -H "Authorization: Bearer $FOUS_API_KEY" \ -H "Content-Type: application/json" \ -d '{"method":"huggingface.co/get_model","input":{"model":"Llama 3.1 8B Instruct"}}' # Save as fous.py, then run: python3 fous.pyimport json, os, timefrom urllib.error import HTTPErrorfrom urllib.request import Request, urlopenAPI = "https://api.fous.com/v1/runs" KEY = os.environ["FOUS_API_KEY"]HEADERS = { "Authorization": f"Bearer {KEY}", "Content-Type": "application/json" ,}def call(url, body=None): data = json.dumps(body).encode() if body else None request = Request(url, data, HEADERS) try: with urlopen(request, timeout=120) as r: return r.status, json.load(r) except HTTPError as error: message = json.load(error)["error"]["message"] raise RuntimeError(message) from errorstatus, run = call(API, { "method": "huggingface.co/get_model" , "input": { "model": "Llama 3.1 8B Instruct" }})# 202: still going after 30 s. Ask again until it ends.while status == 202: time.sleep(2) status, run = call(f"{API}/{run['id']}")print(json.dumps(run["data"], indent=2))// Save as fous.mjs, then run: node fous.mjsconst api = "https://api.fous.com/v1/runs" ;const headers = { Authorization: `Bearer ${process.env.FOUS_API_KEY}`, "Content-Type": "application/json" ,};let response = await fetch(api, { method: "POST", headers, body: JSON.stringify({ "method": "huggingface.co/get_model" , "input": { "model": "Llama 3.1 8B Instruct" } }), signal: AbortSignal.timeout(120_000),});let run = await response.json();// 202: still going after 30 s. Ask again until it ends.while (response.status === 202) { await new Promise((done) => setTimeout(done, 2_000)); response = await fetch(`${api}/${run.id}`, { headers }); run = await response.json();}if (!response.ok) throw new Error(run.error.message);console.log(run.data);# Connect your agent to Fous once, over MCP (Streamable HTTP):# https://api.fous.com/mcp# Set FOUS_API_KEY first: create a key at https://app.fous.com/keys.# Claude Codeclaude mcp add \ --scope user \ --transport http fous https://api.fous.com/mcp \ --header "Authorization: Bearer ${FOUS_API_KEY:?Set FOUS_API_KEY to your Fous API key}"# Codexcodex mcp add fous \ --url https://api.fous.com/mcp \ --bearer-token-env-var FOUS_API_KEY# Cursor, VS Code, Windsurf, Cline and morenpx -y add-mcp https://api.fous.com/mcp -g -n fous \ --header "Authorization: Bearer ${FOUS_API_KEY:?Set FOUS_API_KEY to your Fous API key}"# Then ask your agent:# "Use Fous to run huggingface.co/get_model# with {"model":"Llama 3.1 8B Instruct"}"Over HTTP, the answer’s data holds the output. A run still going after 30 seconds answers 202 with its id: ask GET /v1/runs/{id} until it ends.
Schema
Input schema
{ "type": "object", "required": [ "model" ], "properties": { "model": { "type": "string", "description": "Model name, repository name, or Hugging Face model link, for example Llama 3.1 8B Instruct or meta-llama/Llama-3.1-8B-Instruct." } }, "additionalProperties": false}Output schema
{ "type": "object", "required": [ "model_name", "matched_model", "author", "task", "license", "gated", "downloads_last_30_days", "likes", "last_updated_date", "parameter_count", "base_model", "languages", "datasets_used", "model_card_summary", "files", "model_page_link", "repository_id" ], "properties": { "task": { "type": [ "string", "null" ] }, "files": { "type": "array", "items": { "type": "object", "required": [ "name", "size_bytes" ], "properties": { "name": { "type": "string" }, "size_bytes": { "type": [ "integer", "null" ] } }, "additionalProperties": false } }, "gated": { "type": "boolean", "description": "Whether access to model files requires approval or acceptance." }, "likes": { "type": [ "integer", "null" ] }, "author": { "type": [ "string", "null" ] }, "license": { "type": [ "string", "null" ] }, "languages": { "type": "array", "items": { "type": "string" } }, "base_model": { "type": [ "string", "null" ] }, "model_name": { "type": "string", "description": "Name of the matched model." }, "datasets_used": { "type": "array", "items": { "type": "string" } }, "matched_model": { "type": "string", "description": "The matched model name and publisher, particularly useful for searches by name." }, "repository_id": { "type": "string", "description": "Hugging Face repository ID." }, "model_page_link": { "type": "string" }, "parameter_count": { "type": [ "integer", "null" ] }, "last_updated_date": { "type": [ "string", "null" ] }, "model_card_summary": { "type": [ "string", "null" ] }, "downloads_last_30_days": { "type": [ "integer", "null" ] } }, "additionalProperties": false}- Price
- 1 credit per completed run (1¢ with pay as you go); failed runs are free.
- Method
huggingface.co/get_model- Returns
- model name, matched model, author, task, license, gated, downloads, likes, last updated date, parameter count, base model, languages, datasets, model card summary, files, page link, repository ID
Use it from your agent
Give your agent this line. It reads SKILL.md, gets a Fous API key and connects the Fous MCP server. Its run then takes the method huggingface.co/get_model with the inputs above.
Ask your agent
- What is the license and download count for meta-llama/Llama-3.1-8B-Instruct on Hugging Face?
- Show me the model card summary and file sizes for the Mistral 7B Instruct model.
- Is the gemma-2-9b model gated, and when was it last updated?
- Look up the parameter count and base model for https://huggingface.co/Qwen/Qwen2.5-7B-Instruct.
- Find the author, task type, and number of likes for the Whisper large-v3 model on Hugging Face.
See more
All Hugging Face methodsFinds public Hugging Face models by search words, with an optional task and sort order. License is null when the model does not publish one.
huggingface.co/search_modelsLists Hugging Face models in trending order this week, optionally filtered to one task. Downloads cover the last 30 days.
huggingface.co/list_trending_modelsFinds public Hugging Face datasets by name or topic, ordered by downloads, likes, trending score or last update.
huggingface.co/search_datasetsFinds public Hugging Face Spaces demos for a task, with descriptions, likes, running status and update dates.
huggingface.co/search_spacesLooks up an OpenRouter model by name, slug or model link and returns its prices, limits, supported inputs, release date and hosting providers.
openrouter.ai/get_modelLooks up a public GitHub repository by name, owner/name, or link and returns its stars, forks, release, commit and contributor facts.
github.com/get_repositoryLists the passenger car, SUV/minivan and truck models NHTSA has for a make and model year, alphabetically.
nhtsa.gov/list_vehicle_modelsGets details for an Amazon product, found by name or by link, in a chosen country store. Offer prices, delivery and variants may be missing when Amazon does not show them publicly.
amazon.com/get_product