{"openapi":"3.1.0","info":{"title":"Unfragile API","version":"1.0.0","summary":"Search for everything an agent can invoke: tool actions, every result labelled.","description":"Free, no key. Retrieval and ranking are deterministic; the one language model writes the cited answer behind answer=1 and may only choose among labelled results. Labels: verified and signed · official · checked: not enough evidence yet · found in code, not yet checked · website read, tools not yet checked · demo or tutorial · failed its last check. Never invoke a failed or flagged target. Guides: https://unfragile.ai/docs/agents","contact":{"url":"https://unfragile.ai/about"}},"servers":[{"url":"https://unfragile.ai"}],"paths":{"/api/v1/find":{"get":{"operationId":"findAction","summary":"The tool action that does a task, labelled","parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string","maxLength":500},"description":"The task in plain words, e.g. 'refund a stripe payment'"},{"name":"k","in":"query","schema":{"type":"integer","minimum":1,"maximum":25,"default":10},"description":"How many results, 1 to 25. A value outside that range is used bounded (below 1 as 1, above 25 as 25) and call.warnings in the reply says so; it is never an error."},{"name":"answer","in":"query","schema":{"type":"string","enum":["1"]},"description":"Add a cited answer: a summary, up to six products that do the task, or a question back. Costs 2–10 s; results alone return in under a second."},{"name":"search","in":"query","schema":{"type":"string","maxLength":160},"description":"Optional: your own search phrase (3–10 words). When given, our understanding step is skipped: faster, and the same input always returns the same results."},{"name":"intent","in":"query","schema":{"type":"string","enum":["product","action","model"]},"description":"With search: product (which product does X), action (the one operation to call) or model (which model, read live from Hugging Face)."},{"name":"kind","in":"query","schema":{"type":"string","enum":["product","action","model"]},"description":"The same as intent (the name MCP server 0.11 sends); intent wins when both are given."},{"name":"hf_task","in":"query","schema":{"type":"string","pattern":"^[a-z-]{3,40}$"},"description":"With search and intent=model: the Hugging Face task to read (e.g. text-generation, the default for a model question)."},{"name":"named","in":"query","schema":{"type":"string"},"description":"With search: comma-separated products the request names (e.g. stripe), so they lead."},{"name":"lane","in":"query","schema":{"type":"string","enum":["fast","standard","best"],"default":"standard"},"description":"fast: ranked results, no written answer · standard: as asked · best: a written answer, always fresh, never from memory."},{"name":"max_age","in":"query","schema":{"type":"integer","minimum":0,"maximum":86400},"description":"Seconds: a remembered answer older than this is written afresh; 0 always fresh. The reply's memory object says which you got."},{"name":"client_model","in":"query","schema":{"type":"string","maxLength":100},"description":"The model that will read the answer; recorded on the signed receipt."},{"name":"session_id","in":"query","schema":{"type":"string","maxLength":100},"description":"Your own id for one task; recorded on the signed receipt."},{"name":"debug","in":"query","schema":{"type":"string","enum":["1"]},"description":"1 sends the full body (shape 1): each result's crawled page text and score_parts, and every copy shape 2 leaves out."},{"name":"raw","in":"query","schema":{"type":"string","enum":["1"]},"description":"Search the question's words as typed, without our reading step and without a remembered answer."}],"responses":{"200":{"description":"Ranked, labelled actions","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FindResponse"}}}},"400":{"description":"missing q"},"503":{"description":"The search service is down. Nothing is guessed."}}}},"/api/answer":{"get":{"operationId":"answerRecord","summary":"One verified software record for a need, or an honest no","parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string"},"description":"The need in plain words"}],"responses":{"200":{"description":"One pick with evidence, or answer: null with noConfidentAnswer.reason","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnswerResponse"}}}},"400":{"description":"missing q"}}}},"/api/v1/search":{"get":{"operationId":"searchRecords","summary":"Ranked software records with evidence","parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string","maxLength":200},"description":"What you need, in plain words"},{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":20,"default":5},"description":"How many records, 1 to 20; a value outside is used bounded"}],"responses":{"200":{"description":"results[] with verification, adoption, declared tools, install","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchResponse"}}}},"400":{"description":"missing q"}}}},"/api/v1/resolve":{"post":{"operationId":"resolveIntent","summary":"One intent in; one record, verdict, signed passport and invocation snippet out","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["intent"],"properties":{"intent":{"type":"string","maxLength":200,"description":"What the agent needs to do, in plain words"}}}}}},"responses":{"200":{"description":"resolved (or null) + alternatives","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResolveResponse"}}}},"400":{"description":"invalid JSON, or missing intent"}}},"get":{"operationId":"resolveIntentGet","summary":"The same as POST, with the intent in the query","parameters":[{"name":"intent","in":"query","schema":{"type":"string","maxLength":200},"description":"What the agent needs to do (q is accepted too)"},{"name":"q","in":"query","schema":{"type":"string","maxLength":200},"description":"The same as intent; intent wins when both are given"}],"responses":{"200":{"description":"resolved (or null) + alternatives","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResolveResponse"}}}},"400":{"description":"missing intent"}}}},"/api/v1/verify":{"post":{"operationId":"verifyTarget","summary":"Verdict before you invoke: trusted · caution · unverified · flagged","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["target"],"properties":{"target":{"type":"string","description":"npm:…, pypi:…, mcp:…, a package name or a record id"}}}}}},"responses":{"200":{"description":"verdict, reason, record, signed passport","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VerifyResponse"}}}}}},"get":{"operationId":"verifyTargetGet","summary":"The same as POST, with the target in the query","parameters":[{"name":"target","in":"query","schema":{"type":"string","maxLength":200},"description":"npm:…, pypi:…, mcp:…, a package name or a record id (slug is accepted too)"},{"name":"slug","in":"query","schema":{"type":"string","maxLength":200},"description":"A record page slug; the same as target, and slug wins when both are given"}],"responses":{"200":{"description":"verdict, reason, record, signed passport","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VerifyResponse"}}}}}}},"/api/v1/passport/{id}":{"get":{"operationId":"getPassport","summary":"The Ed25519-signed trust passport of a verified record","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"},"description":"URL-encoded record id or record page slug"}],"responses":{"200":{"description":"passport + _links.publicKey","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PassportResponse"}}}},"404":{"description":"not a verified record, or no passport yet"}}}},"/api/v1/stats":{"get":{"operationId":"getStats","summary":"Live index numbers by door type","responses":{"200":{"description":"listed, verified, signedPassports, official, byEnvelope","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatsResponse"}}}}}}},"/api/mcp":{"post":{"operationId":"mcp","summary":"The hosted MCP door: stateless MCP over HTTP (initialize, tools/list, tools/call unfragile_find, ping), no key needed. claude mcp add --transport http unfragile https://unfragile.ai/api/mcp","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","description":"one JSON-RPC 2.0 message"}}}},"responses":{"200":{"description":"the JSON-RPC reply"},"202":{"description":"a notification, acknowledged"},"400":{"description":"not JSON, or a batch"}}}},"/api/v1/trust-passport-public-key":{"get":{"operationId":"getPublicKey","summary":"The Ed25519 public key for offline passport checks","responses":{"200":{"description":"publicKey (base64)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicKeyResponse"}}}}}}}},"components":{"schemas":{"Tier":{"type":"string","enum":["verified","official","checked","found-in-code","retired","demo","failed","unknown"]},"Label":{"type":"string","description":"what tierLabel returns for each tier","enum":["verified and signed","official","checked: not enough evidence yet","found in code, not yet checked","demo or tutorial","failed its last check","website read, tools not yet checked","Retired by its maker. Still installs, but no longer updated.","Retired by its maker. The repository is archived.","Retired by its maker."]},"FindResult":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string","description":"the product's name as shown (the same as product since results are the picks)"},"product":{"type":"string","nullable":true,"description":"the product name"},"vendor":{"type":"string","nullable":true,"description":"the maker's website domain (gh:<owner> for a repository listing)"},"record_name":{"type":"string","nullable":true,"description":"our record's own name, when the row shows the name a leader was proposed by"},"action":{"type":"string"},"description":{"type":"string"},"from":{"type":"string","enum":["declared","source"],"nullable":true},"tier":{"$ref":"#/components/schemas/Tier"},"label":{"$ref":"#/components/schemas/Label"},"official":{"type":"boolean"},"status":{"type":"string","nullable":true},"downloads_monthly":{"type":"integer","nullable":true},"url":{"type":"string","nullable":true,"description":"signed passport, verified records only"},"page":{"type":"object","nullable":true,"description":"the maker's page we read: title, url, fetched_at (its text only with debug=1)","properties":{"title":{"type":"string"},"url":{"type":"string"},"fetched_at":{"type":"string"}}},"score_parts":{"type":"object","description":"the ranking score term by term; only with debug=1"},"source":{"type":"object","nullable":true,"properties":{"envelope":{"type":"string"},"repo":{"type":"string","nullable":true},"npm":{"type":"string","nullable":true},"page":{"type":"string","nullable":true},"stars":{"type":"integer","nullable":true},"downloads_monthly":{"type":"integer","nullable":true},"last_verified":{"type":"string","nullable":true},"install":{"type":"string","nullable":true}}}}},"ProductCard":{"type":"object","description":"One product that does the task, written from its own page; trust labels come from our checks, never from the writer. In body shape 2 the card holds the row's doors, actions, install line and links; results[] holds its identity, label, use and page, matched by result_id.","properties":{"result_id":{"type":"string","description":"the id of its row in results[]"},"vendor":{"type":"string","nullable":true,"description":"the maker's website domain"},"name":{"type":"string"},"what":{"type":"string","description":"one sentence, with [n] citations into answer.sources"},"cites":{"type":"array","items":{"type":"integer"}},"retired":{"type":"boolean","description":"its own page says it is retired; listed last"},"links":{"type":"object","properties":{"website":{"type":"string","nullable":true},"docs":{"type":"string","nullable":true},"pricing":{"type":"string","nullable":true},"signup":{"type":"string","nullable":true}}},"tier":{"$ref":"#/components/schemas/Tier"},"label":{"$ref":"#/components/schemas/Label"},"actions":{"type":"array","maxItems":5,"description":"shape 2: at most 3, each {action, tier} plus id when it is not the card's own record","items":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"action":{"type":"string"},"label":{"type":"string"},"tier":{"$ref":"#/components/schemas/Tier"},"url":{"type":"string","nullable":true}}}},"doors":{"type":"array","maxItems":5,"description":"its own listings (MCP server, API, SDK, CLI), official first; shape 2: at most 3, not the row's own record, label only when it differs from the card's","items":{"type":"object","properties":{"name":{"type":"string"},"kind":{"type":"string"},"official":{"type":"boolean"},"label":{"$ref":"#/components/schemas/Label"},"link":{"type":"string","nullable":true}}}},"community":{"type":"integer","description":"how many community tools are about it"},"documented":{"type":"object","nullable":true,"description":"an operation from the maker's own docs, not yet checked by us","properties":{"operation":{"type":"string"},"checked":{"type":"boolean","enum":[false]}}}}},"SuggestedCard":{"type":"object","description":"A real product found outside our index, checked to exist at its link, not verified by us.","properties":{"name":{"type":"string"},"maker":{"type":"string"},"url":{"type":"string"},"what":{"type":"string"},"kind":{"type":"string","enum":["huggingface","npm","pypi","github","website"]},"verified":{"type":"boolean","enum":[false]},"source":{"type":"string","enum":["suggested"]},"released":{"type":"string","nullable":true,"description":"model questions: release date on Hugging Face"},"base":{"type":"string","nullable":true,"description":"model questions: the model a community derivative is built on"}}},"FindAnswer":{"type":"object","description":"Present only with answer=1. When nothing fits, products is empty and fit is 0.","properties":{"kind":{"type":"string","enum":["product","action","model"]},"summary":{"type":"string","description":"one or two sentences, with [n] citations"},"products":{"type":"array","maxItems":6,"items":{"$ref":"#/components/schemas/ProductCard"},"description":"best first; the first `fit` do the main job, the rest are closest fits"},"fit":{"type":"integer","minimum":0,"maximum":6},"gap":{"type":"string","nullable":true,"description":"only when fit is 0: what the nearest tools do instead and what they cannot, naming no product"},"suggested":{"type":"array","items":{"$ref":"#/components/schemas/SuggestedCard"},"description":"models for a model question; otherwise only when fit is below 2"},"question":{"type":"string","nullable":true,"description":"one thing asked back when the request is ambiguous"},"sources":{"type":"array","items":{"type":"object","properties":{"n":{"type":"integer"},"title":{"type":"string"},"url":{"type":"string"},"fetched_at":{"type":"string"},"live":{"type":"boolean"}}}},"retired":{"type":"array","items":{"type":"string"},"description":"products left out because their own page says they are retired"},"model":{"type":"string"},"ms":{"type":"object","additionalProperties":{"type":"number"}},"error":{"type":"string","description":"present when the answer layer failed; nothing is made up"}}},"AnswerResponse":{"type":"object","properties":{"query":{"type":"string","description":"the question as asked"},"read_as":{"type":"string","description":"how the question was read"},"answer":{"type":"object","nullable":true,"description":"the one pick with its evidence (tier, score, signed passport, freshness, adoption) and an install command; null when nothing covers the question confidently"},"alternatives":{"type":"array","items":{"type":"object"},"description":"honest alternatives, each with its status and a note"},"noConfidentAnswer":{"type":"object","description":"present when answer is null: reason says why"},"corpus":{"type":"object","description":"the index size and the engine that answered"},"_links":{"type":"object","description":"this call and the docs"},"engine":{"type":"string","enum":["find"],"description":"the engine that answered: the find answer, the same products in the same order as /api/v1/find?answer=1"},"search_id":{"type":"string","description":"this call's id in the search log"},"memory":{"type":"object","description":"whether the answer came from memory, as on /api/v1/find","properties":{"from_memory":{"type":"boolean"},"matched_on":{"type":"string","enum":["question","reading"]},"answered_at":{"type":"string"},"age_s":{"type":"number"},"max_age_s":{"type":"number","nullable":true}}}}},"SearchResponse":{"type":"object","properties":{"query":{"type":"string","description":"the question as asked"},"read_as":{"type":"string","description":"how the question was read"},"results":{"type":"array","items":{"type":"object"},"description":"ranked records, each with its envelope, verification status and score, signed-passport flag, adoption, declared tools, install command and evidence page"},"corpus":{"type":"object","description":"the index size and the engine"},"method":{"type":"string","description":"how the results were ranked"},"_links":{"type":"object","description":"the one-answer call and the docs"},"engine":{"type":"string","enum":["find"],"description":"the engine that answered: results are /api/v1/find?answer=1's products in its order"},"search_id":{"type":"string","description":"this call's id in the search log"},"memory":{"type":"object","description":"whether the answer came from memory, as on /api/v1/find"},"answer_error":{"type":"string","description":"present when the answer layer failed; results are then as searched"}}},"ResolveResponse":{"type":"object","properties":{"intent":{"type":"string","description":"the intent as given"},"read_as":{"type":"string","description":"how the intent was read"},"resolved":{"type":"object","nullable":true,"description":"the one verified record with its verdict, signed passport and invocation snippet; null when nothing qualifies (do not invoke a guess)"},"alternatives":{"type":"array","items":{"type":"object"},"description":"other products that do the task, each with its tier"},"suggested":{"type":"array","items":{"type":"object"},"description":"real products found outside the index, not verified by us"},"method":{"type":"string","description":"the engine that answered"},"_links":{"type":"object","description":"the same answer on the website, and the trust spec"}}},"VerifyResponse":{"type":"object","properties":{"target":{"type":"string","description":"the target as given"},"verdict":{"type":"string","enum":["trusted","caution","unverified","flagged"],"description":"never invoke a flagged target; an unknown target is never trusted"},"reason":{"type":"string","description":"why this verdict, in one sentence"},"notes":{"type":"array","items":{"type":"string"},"description":"what the tool's contract asks of the agent that does not change the verdict; absent when there is nothing"},"known":{"type":"boolean","description":"whether the target is in the index"},"record":{"type":"object","nullable":true,"description":"the record behind the verdict"},"passport":{"type":"object","nullable":true,"description":"the record's Ed25519-signed passport"},"method":{"type":"string","description":"how the verdict was decided"},"_links":{"type":"object","description":"the trust spec and the docs"}}},"PassportResponse":{"type":"object","properties":{"passport":{"type":"object","description":"the signed passport: what was checked and when, with signature, signedAt, signedBy and version"},"_links":{"type":"object","description":"the public key to check it with, and the spec"}}},"StatsResponse":{"type":"object","properties":{"corpus":{"type":"object","description":"listed, verified, signedPassports, official, and byEnvelope"},"methodology":{"type":"string","description":"the page that explains the numbers"},"method":{"type":"string","description":"where the numbers are counted from"}}},"PublicKeyResponse":{"type":"object","properties":{"publicKey":{"type":"string","description":"the Ed25519 public key, base64"},"algorithm":{"type":"string","description":"ed25519"},"issuer":{"type":"string","description":"unfragile.ai"},"version":{"type":"integer","description":"the passport version the key signs"},"_links":{"type":"object","description":"the spec and the schema"}}},"FindResponse":{"type":"object","properties":{"query":{"type":"string","description":"the question as asked"},"intent":{"type":"string","enum":["product","action","model"],"description":"how the question was read"},"named":{"type":"array","items":{"type":"string"},"description":"products the question names; they lead"},"searched_as":{"type":"string","description":"the search phrase that was run"},"understand_ms":{"type":"number","description":"time to read the question, ms"},"understand_error":{"type":"string","nullable":true,"description":"the reading step's failure, if any; the question is then searched as typed"},"retired":{"type":"array","items":{"type":"string"},"description":"products left out because their own page says they are retired"},"results":{"type":"array","items":{"$ref":"#/components/schemas/FindResult"},"description":"the ranked, labelled results"},"timing_ms":{"type":"object","additionalProperties":{"type":"number"},"description":"time per step of the search, ms"},"wall_ms":{"type":"object","additionalProperties":{"type":"number"},"description":"time per stage of this call (understand, box, sources, answer), ms"},"method":{"type":"string","description":"how the results were ranked"},"labels":{"type":"string","description":"every label a result can carry"},"answer":{"$ref":"#/components/schemas/FindAnswer"},"answered_at":{"type":"string","description":"when the answer was written (ISO 8601); with answer=1"},"facts":{"type":"object","description":"present when the question asks for a fact we may hold: what was asked and how many readings were stated, held, not stated or not yet read","properties":{"ask":{"type":"object"},"status":{"type":"object","properties":{"stated":{"type":"integer"},"held":{"type":"integer"},"not_stated":{"type":"integer"},"not_yet_read":{"type":"integer"}}},"held_while_terms_pending":{"type":"boolean"},"fact_only":{"type":"boolean"},"lookup_ms":{"type":"number"}}},"memory":{"type":"object","description":"with answer=1: whether the answer came from memory","properties":{"from_memory":{"type":"boolean"},"matched_on":{"type":"string","enum":["question","reading"]},"answered_at":{"type":"string"},"age_s":{"type":"number"},"max_age_s":{"type":"number","nullable":true}}},"call":{"type":"object","description":"the call settings as read: lane, client_model, session_id, and warnings for anything ignored or bounded","properties":{"lane":{"type":"string"},"client_model":{"type":"string","nullable":true},"session_id":{"type":"string","nullable":true},"warnings":{"type":"array","items":{"type":"string"}}}},"search_id":{"type":"string","description":"this search's id; the signed receipt carries the same id"},"blocks":{"type":"array","items":{"type":"object"},"description":"the answer as typed pieces in reading order (summary, gap, pick, question, suggested, sources, receipt); in body shape 2 a pick names its row by result_id and its card by rank, and the sources piece points at answer.sources; see /docs/receipts#typed-pieces"},"shape":{"type":"string","enum":["2"],"description":"2: each row is sent once (results[] reference answer.products by result_id; a door says its label only when it differs from its card's; method and labels are left out). Absent with debug=1, which sends shape 1."},"receipt":{"type":"object","description":"the Ed25519-signed receipt: what ran, why, when, the cost, and digests of this body; see /docs/receipts"}}}}}}