{"openapi":"3.1.0","info":{"title":"Deshboard official data API","version":"1","description":"India's official figures as each publisher printed them, with the release behind every value (and its SHA-256 where recorded). Read-only, no key. Figures are reproduced as each publisher printed them, with the source named. Cite the publisher and release first, then Deshboard. Publisher terms apply: MoSPI's dissemination guidelines, the Ministry of Finance's Budget documents, and the RBI's and NCRB's own terms, which reserve their rights."},"servers":[{"url":"https://deshboard.app/api/v1"}],"paths":{"/series":{"get":{"summary":"Every open series with its latest figure","responses":{"200":{"description":"The catalogue.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Catalogue"}}}}}}},"/series/{id}":{"get":{"summary":"Every observation of one series, as printed","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","enum":["cpi-headline","cpi-food","fiscal-deficit","fiscal-deficit-to-gdp","capital-expenditure","gdp-growth","per-capita-income","repo-rate","rupee-dollar","rupee-dollar-yearly","forex-reserves","forex-reserves-yearly","unemployment-rate","unemployment-rate-yearly","crime-rate","crimes-registered","crimes-against-women","cyber-crimes"]}},{"name":"from","in":"query","schema":{"type":"string"}},{"name":"to","in":"query","schema":{"type":"string"}}],"responses":{"200":{"description":"The series.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Series"}}}},"404":{"description":"Unknown series, or no observation for that period.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"The family has nothing published yet, or a read failed.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/latest/{id}":{"get":{"summary":"The figure the page leads with","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","enum":["cpi-headline","cpi-food","fiscal-deficit","fiscal-deficit-to-gdp","capital-expenditure","gdp-growth","per-capita-income","repo-rate","rupee-dollar","rupee-dollar-yearly","forex-reserves","forex-reserves-yearly","unemployment-rate","unemployment-rate-yearly","crime-rate","crimes-registered","crimes-against-women","cyber-crimes"]}}],"responses":{"200":{"description":"The latest figure.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Latest"}}}},"404":{"description":"Unknown series, or no observation for that period.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"The family has nothing published yet, or a read failed.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/compare":{"get":{"summary":"Two periods of one series, and whether the change may be stated","parameters":[{"name":"series","in":"query","required":true,"schema":{"type":"string","enum":["cpi-headline","cpi-food","fiscal-deficit","fiscal-deficit-to-gdp","capital-expenditure","gdp-growth","per-capita-income","repo-rate","rupee-dollar","rupee-dollar-yearly","forex-reserves","forex-reserves-yearly","unemployment-rate","unemployment-rate-yearly","crime-rate","crimes-registered","crimes-against-women","cyber-crimes"]}},{"name":"from","in":"query","required":true,"schema":{"type":"string"}},{"name":"to","in":"query","required":true,"schema":{"type":"string"}},{"name":"dimension","in":"query","schema":{"type":"string"}}],"responses":{"200":{"description":"The comparison.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Compare"}}}},"400":{"description":"Missing parameters.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Unknown series, or no observation for that period.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"The family has nothing published yet, or a read failed.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/releases":{"get":{"summary":"When each family last released and is next due","responses":{"200":{"description":"The release calendar.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Releases"}}}}}}}},"components":{"schemas":{"Catalogue":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"series":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"title":{"type":"string"},"publisher":{"type":"string"},"pageUrl":{"type":"string"},"state":{"type":"string","enum":["available","unavailable"]},"latest":{"anyOf":[{"type":"object","properties":{"period":{"type":"string"},"value":{"type":"number"},"unit":{"type":"string"},"dimension":{"type":["string","null"]},"qualifier":{"type":["string","null"]},"segment":{"type":"string"},"release":{"type":"string"}},"required":["period","value","unit","dimension","qualifier","segment","release"],"additionalProperties":false},{"type":"null"}]}},"required":["id","title","publisher","pageUrl","state","latest"],"additionalProperties":false}},"licence":{"type":"string"},"generatedAt":{"type":"string"}},"required":["series","licence","generatedAt"],"additionalProperties":false},"Series":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"series":{"type":"object","properties":{"id":{"type":"string"},"title":{"type":"string"},"publisher":{"type":"string"},"pageUrl":{"type":"string"},"periodKind":{"type":"string","enum":["month","financial-year","year","date","survey-year"]},"unit":{"type":"string"},"primaryDimension":{"type":["string","null"]},"segments":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"label":{"type":"string"}},"required":["id","label"],"additionalProperties":false}}},"required":["id","title","publisher","pageUrl","periodKind","unit","primaryDimension","segments"],"additionalProperties":false},"observations":{"type":"array","items":{"type":"object","properties":{"period":{"type":"string"},"value":{"type":"number"},"unit":{"type":"string"},"dimension":{"type":["string","null"]},"qualifier":{"type":["string","null"]},"segment":{"type":"string"},"release":{"type":"string"}},"required":["period","value","unit","dimension","qualifier","segment","release"],"additionalProperties":false}},"releases":{"type":"array","items":{"type":"object","properties":{"slug":{"type":"string"},"title":{"type":"string"},"publishedOn":{"type":"string"},"sourceUrl":{"type":"string"},"contentSha256":{"type":["string","null"]}},"required":["slug","title","publishedOn","sourceUrl","contentSha256"],"additionalProperties":false}},"dataVersion":{"type":"string"},"citation":{"type":"object","properties":{"text":{"type":"string"},"publisher":{"type":"string"},"pageUrl":{"type":"string"}},"required":["text","publisher","pageUrl"],"additionalProperties":false},"licence":{"type":"string"}},"required":["series","observations","releases","dataVersion","citation","licence"],"additionalProperties":false},"Latest":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"series":{"type":"object","properties":{"id":{"type":"string"},"title":{"type":"string"},"publisher":{"type":"string"},"pageUrl":{"type":"string"},"periodKind":{"type":"string","enum":["month","financial-year","year","date","survey-year"]},"unit":{"type":"string"},"primaryDimension":{"type":["string","null"]},"segments":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"label":{"type":"string"}},"required":["id","label"],"additionalProperties":false}}},"required":["id","title","publisher","pageUrl","periodKind","unit","primaryDimension","segments"],"additionalProperties":false},"latest":{"type":"object","properties":{"period":{"type":"string"},"value":{"type":"number"},"unit":{"type":"string"},"dimension":{"type":["string","null"]},"qualifier":{"type":["string","null"]},"segment":{"type":"string"},"release":{"type":"string"}},"required":["period","value","unit","dimension","qualifier","segment","release"],"additionalProperties":false},"release":{"anyOf":[{"type":"object","properties":{"slug":{"type":"string"},"title":{"type":"string"},"publishedOn":{"type":"string"},"sourceUrl":{"type":"string"},"contentSha256":{"type":["string","null"]}},"required":["slug","title","publishedOn","sourceUrl","contentSha256"],"additionalProperties":false},{"type":"null"}]},"dataVersion":{"type":"string"},"citation":{"type":"object","properties":{"text":{"type":"string"},"publisher":{"type":"string"},"pageUrl":{"type":"string"}},"required":["text","publisher","pageUrl"],"additionalProperties":false},"licence":{"type":"string"}},"required":["series","latest","release","dataVersion","citation","licence"],"additionalProperties":false},"Compare":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"series":{"type":"object","properties":{"id":{"type":"string"},"title":{"type":"string"},"publisher":{"type":"string"},"pageUrl":{"type":"string"},"periodKind":{"type":"string","enum":["month","financial-year","year","date","survey-year"]},"unit":{"type":"string"},"primaryDimension":{"type":["string","null"]},"segments":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"label":{"type":"string"}},"required":["id","label"],"additionalProperties":false}}},"required":["id","title","publisher","pageUrl","periodKind","unit","primaryDimension","segments"],"additionalProperties":false},"from":{"type":"object","properties":{"period":{"type":"string"},"value":{"type":"number"},"unit":{"type":"string"},"dimension":{"type":["string","null"]},"qualifier":{"type":["string","null"]},"segment":{"type":"string"},"release":{"type":"string"}},"required":["period","value","unit","dimension","qualifier","segment","release"],"additionalProperties":false},"to":{"type":"object","properties":{"period":{"type":"string"},"value":{"type":"number"},"unit":{"type":"string"},"dimension":{"type":["string","null"]},"qualifier":{"type":["string","null"]},"segment":{"type":"string"},"release":{"type":"string"}},"required":["period","value","unit","dimension","qualifier","segment","release"],"additionalProperties":false},"comparability":{"type":"object","properties":{"status":{"type":"string","enum":["COMPARABLE","LIMITED","NOT_COMPARABLE"]},"reasons":{"type":"array","items":{"type":"string"}}},"required":["status","reasons"],"additionalProperties":false},"difference":{"type":["number","null"]},"citation":{"type":"object","properties":{"text":{"type":"string"},"publisher":{"type":"string"},"pageUrl":{"type":"string"}},"required":["text","publisher","pageUrl"],"additionalProperties":false},"licence":{"type":"string"}},"required":["series","from","to","comparability","difference","citation","licence"],"additionalProperties":false},"Releases":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"releases":{"type":"array","items":{"type":"object","properties":{"family":{"type":"string"},"label":{"type":"string"},"publisher":{"type":"string"},"latest":{"anyOf":[{"type":"object","properties":{"period":{"type":"string"},"publishedOn":{"type":["string","null"]}},"required":["period","publishedOn"],"additionalProperties":false},{"type":"null"}]},"next":{"type":["string","null"]},"nextEstimate":{"anyOf":[{"type":"object","properties":{"from":{"type":"string"},"to":{"type":"string"}},"required":["from","to"],"additionalProperties":false},{"type":"null"}]},"behind":{"type":["string","null"]},"publisherCalendar":{"type":["string","null"]}},"required":["family","label","publisher","latest","next","nextEstimate","behind","publisherCalendar"],"additionalProperties":false}},"generatedAt":{"type":"string"}},"required":["releases","generatedAt"],"additionalProperties":false},"Error":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"error":{"type":"string","enum":["unknown-series","unavailable","no-observation","bad-request"]},"message":{"type":"string"}},"required":["error","message"],"additionalProperties":false}}}}