{
 "openapi": "3.0.3",
 "info": {
  "title": "Miliroute taxi demand estimates",
  "version": "1",
  "description": "Model estimates of taxi pickups by area, weekday and half-hour (strict zero-shot transfer; not checked against real trips). Licence: CC BY 4.0.",
  "license": {
   "name": "CC BY 4.0",
   "url": "https://creativecommons.org/licenses/by/4.0/"
  }
 },
 "servers": [
  {
   "url": "https://miliroute.com/taxi-demand/api/v1"
  }
 ],
 "paths": {
  "/cities.json": {
   "get": {
    "summary": "All published cities",
    "responses": {
     "200": {
      "description": "City list",
      "content": {
       "application/json": {}
      }
     },
     "404": {
      "description": "Unknown city"
     }
    }
   }
  },
  "/{country}/{slug}.json": {
   "get": {
    "summary": "One city: areas, map paths, rhythm, share_ws",
    "parameters": [
     {
      "name": "country",
      "in": "path",
      "required": true,
      "schema": {
       "type": "string",
       "enum": [
        "united-states",
        "united-kingdom",
        "canada",
        "australia"
       ]
      }
     },
     {
      "name": "slug",
      "in": "path",
      "required": true,
      "schema": {
       "type": "string",
       "pattern": "^[a-z0-9-]+$"
      }
     }
    ],
    "responses": {
     "200": {
      "description": "City file",
      "content": {
       "application/json": {}
      }
     },
     "404": {
      "description": "Unknown city"
     }
    }
   }
  },
  "/{country}/{slug}/areas.csv": {
   "get": {
    "summary": "Areas ranked by yearly share",
    "parameters": [
     {
      "name": "country",
      "in": "path",
      "required": true,
      "schema": {
       "type": "string",
       "enum": [
        "united-states",
        "united-kingdom",
        "canada",
        "australia"
       ]
      }
     },
     {
      "name": "slug",
      "in": "path",
      "required": true,
      "schema": {
       "type": "string",
       "pattern": "^[a-z0-9-]+$"
      }
     }
    ],
    "responses": {
     "200": {
      "description": "CSV",
      "content": {
       "text/csv": {}
      }
     },
     "404": {
      "description": "Unknown city"
     }
    }
   }
  },
  "/{country}/{slug}/week.csv.gz": {
   "get": {
    "summary": "Long format: area, weekday, half_hour, share",
    "parameters": [
     {
      "name": "country",
      "in": "path",
      "required": true,
      "schema": {
       "type": "string",
       "enum": [
        "united-states",
        "united-kingdom",
        "canada",
        "australia"
       ]
      }
     },
     {
      "name": "slug",
      "in": "path",
      "required": true,
      "schema": {
       "type": "string",
       "pattern": "^[a-z0-9-]+$"
      }
     }
    ],
    "responses": {
     "200": {
      "description": "Gzipped CSV",
      "content": {
       "application/gzip": {}
      }
     },
     "404": {
      "description": "Unknown city"
     }
    }
   }
  }
 }
}