{"openapi":"3.1.0","info":{"title":"Namashkar Bharat directory API","version":"1.0.0","summary":"Read-only directory of official Government of India websites.","description":"Namashkar Bharat is an independent guide. It is not a government website and is not affiliated with, endorsed by or operated by the Government of India or any state government. Every entry is the website of a government body, PSU or statutory authority. The directory is public, read-only and needs no key. For search, URL verification and step-by-step playbooks, use the MCP connector at https://namashkarbharat.com/mcp (setup: https://namashkarbharat.com/agents; not described by this document). Errors are RFC 9457 application/problem+json with a stable `code` and a `hint`; every code is documented at https://namashkarbharat.com/developers#errors. There are no API keys: the API is public and read-only.","contact":{"name":"Namashkar Bharat","url":"https://x.com/ajinkya_shejul"}},"servers":[{"url":"https://namashkarbharat.com"}],"security":[],"externalDocs":{"description":"Developer portal: examples, rate limits, caching, error codes, fair use","url":"https://namashkarbharat.com/developers"},"paths":{"/api/directory":{"get":{"operationId":"getDirectory","summary":"List every official website in the directory","description":"Returns the whole directory in one response (no paging or filtering). Cached publicly for up to a day; CORS allows any origin for GET and no credentials are used. Ids are slugs of the site name and stay stable while the name does.","responses":{"200":{"description":"The directory","headers":{"Cache-Control":{"schema":{"type":"string"},"description":"public, max-age=3600, s-maxage=86400, stale-while-revalidate=604800"},"Access-Control-Allow-Origin":{"schema":{"type":"string","const":"*"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Directory"}}}},"4XX":{"$ref":"#/components/responses/ClientError"},"5XX":{"$ref":"#/components/responses/ServerError"}}}}},"components":{"responses":{"ClientError":{"description":"Client error (for example 404 not_found or 405 method_not_allowed), as RFC 9457 problem details","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://namashkarbharat.com/developers#errors-not_found","title":"Not found","status":404,"detail":"There is no API endpoint at this path.","code":"not_found","hint":"See /developers for the available endpoints and /openapi.json for their description."}}}},"ServerError":{"description":"Unexpected server error, as RFC 9457 problem details","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"},"example":{"type":"https://namashkarbharat.com/developers#errors-server_error","title":"Server error","status":500,"detail":"Something unexpected failed on our side. Nothing was stored.","code":"server_error","hint":"Retry later. If it keeps happening, report it on X (@ajinkya_shejul)."}}}}},"schemas":{"Problem":{"type":"object","description":"RFC 9457 problem details. `type` links to the code's entry on https://namashkarbharat.com/developers#errors. Other extension members may be present.","required":["type","title","status","detail","code","hint"],"properties":{"type":{"type":"string","format":"uri","description":"URI identifying the problem type; dereferences to its documentation","examples":["https://namashkarbharat.com/developers#errors-not_found"]},"title":{"type":"string","description":"Short, human-readable summary of the problem type"},"status":{"type":"integer","minimum":400,"maximum":599,"description":"HTTP status code"},"detail":{"type":"string","description":"Human-readable explanation of this occurrence"},"instance":{"type":"string","format":"uri-reference","description":"URI reference identifying this occurrence (not currently sent)"},"code":{"type":"string","enum":["bad_request","too_short","too_long","links","gibberish","forbidden","verify","unknown_search","not_found","method_not_allowed","too_large","unsupported_type","burst","daily","rate_limited","server_error"],"description":"Stable machine-readable error code (extension member)"},"hint":{"type":"string","description":"What to do next (extension member)"}},"additionalProperties":true},"Directory":{"type":"object","required":["count","sites","categories"],"properties":{"count":{"type":"integer","description":"Number of sites"},"categories":{"type":"array","items":{"$ref":"#/components/schemas/Category"}},"sites":{"type":"array","items":{"$ref":"#/components/schemas/Site"}}}},"Category":{"type":"object","required":["id","name","blurb","url"],"properties":{"id":{"type":"string","enum":["identity","tax","business","jobs","education","health","agriculture","environment","transport","welfare","housing","justice","governance","digital","international","states","culture","science"]},"name":{"type":"string","description":"English name"},"blurb":{"type":"string","description":"English one-line description"},"url":{"type":"string","format":"uri","description":"Category page on namashkarbharat.com"}}},"Site":{"type":"object","required":["id","name","url","domain","category"],"properties":{"id":{"type":"string","pattern":"^[a-z0-9-]+$","description":"Stable slug id","examples":["passport-seva"]},"name":{"type":"string","description":"Site name (English)"},"url":{"type":"string","format":"uri","description":"Official URL on the owning body's own domain"},"domain":{"type":"string","description":"Hostname without www.","examples":["passportindia.gov.in"]},"category":{"type":"string","enum":["identity","tax","business","jobs","education","health","agriculture","environment","transport","welfare","housing","justice","governance","digital","international","states","culture","science"]},"desc":{"type":"string","description":"One-line English description"},"tags":{"type":"array","items":{"type":"string"},"description":"Lowercase keywords"},"org":{"type":"string","description":"Owning ministry, department or body (may be empty)"},"state":{"type":"string","enum":["AN","AP","AR","AS","BR","CG","CH","DH","DL","GA","GJ","HP","HR","JH","JK","KA","KL","LA","LD","MH","ML","MN","MP","MZ","NL","OD","PB","PY","RJ","SK","TG","TN","TR","UK","UP","WB"],"description":"ISO 3166-2:IN code (without \"IN-\") of the one state or union territory the site serves; absent for national sites","examples":["MH"]}}}}}}