Country State City API
March 28, 2026 · View on GitHub
Interactive API documentation for the Country State City API.
Live: playground.countrystatecity.in
What this is
A static Swagger UI deployment hosted on GitHub Pages. The OpenAPI 3.0 spec lives in config.json and documents all geographic data endpoints, data access levels, and error responses.
Endpoints
See the live playground for full endpoint documentation, request/response schemas, and tier availability.
Pricing & Limits
Current tiers, limits, and data access levels are always available at:
Local Development
No build step required. Open index.html in a browser or serve with any static file server:
npx serve .
Updating the Spec
Edit config.json directly. It's a standard OpenAPI 3.0.3 document. Push to main and GitHub Pages deploys automatically.
When updating, keep in sync with:
- Routes:
csc-app/api/src/routes/world.routes.ts - Tier config:
csc-app/api/src/config/pricingTiers.ts - Field access:
csc-app/api/src/services/dataAccessService.ts
Links
- Pricing: app.countrystatecity.in/pricing
- API Dashboard: app.countrystatecity.in
- Main API: api.countrystatecity.in/v1
- Database repo: github.com/dr5hn/countries-states-cities-database