City details

BasicStartupBusinessEnterprise
GET/cities/{id}

Get all the details about a specific city.

Name Type Required Description
{id} path parameter String required city's slug
from query parameter String optional city's slug if you want to include comparison data which is available on some data categories (eg. weather)
curl --request GET \
     --url 'https://api.thebasetrip.com/v3/cities/paris?from=london' \
     --header 'Accept: application/json' \
     --header 'x-api-key: {api-key}'
Name Type Description
basic Object Basic category
weather Object Weather category
publicTransportation Object Public transportation category
rideSharing Object Ride sharing category
embassy Object Embassy category
{
  "basic": {
    "slug": "paris",
    "name": {
      "common": "Paris"
    },
    "country": {
      "alpha2code": "FR",
      "name": "France",
      "slug": "france"
    },
    "code": {
      "iata": "PAR"
    },
    "coordinates": {
      "latitude": 48.856614,
      "longitude": 2.3522219
    },
    "timeZone": "Europe/Paris",
    "isCapital": true,
    "wikipediaUrl": "https://en.wikipedia.org/wiki/Paris",
    "textual": {
      "title": "France",
      "sections": [
        {
          "id": "LOCATION",
          "body": [
            "Paris is the capital city of France."
          ]
        },
        {
          "id": "SUMMARY",
          "body": [
            "Official language is French. France uses metric system (kilograms, centimeters, °C). Current time in Paris is 12:10 which is 1 hour ahead of London."
          ]
        }
      ]
    }
  },
  "weather": {
    "monthly": [
      {
        "month": 1,
        "temperature": {
          "min": 3.57,
          "max": 8.07
        },
        "sun": {
          "sunrise": 517,
          "sunset": 1043,
          "daylight": 526
        }
      },
      {
        "month": 2,
        "temperature": {
          "min": 3.68,
          "max": 8.98
        },
        "sun": {
          "sunrise": 480,
          "sunset": 1090,
          "daylight": 610
        }
      },
      {
        "month": 3,
        "temperature": {
          "min": 4.1,
          "max": 10.11
        },
        "sun": {
          "sunrise": 431,
          "sunset": 1147,
          "daylight": 716
        }
      },
      {
        "month": 4,
        "temperature": {
          "min": 6.19,
          "max": 13.85
        },
        "sun": {
          "sunrise": 419,
          "sunset": 1243,
          "daylight": 824
        }
      },
      {
        "month": 5,
        "temperature": {
          "min": 10.22,
          "max": 18.65
        },
        "sun": {
          "sunrise": 369,
          "sunset": 1287,
          "daylight": 918
        }
      },
      {
        "month": 6,
        "temperature": {
          "min": 14.14,
          "max": 20.9
        },
        "sun": {
          "sunrise": 348,
          "sunset": 1315,
          "daylight": 967
        }
      },
      {
        "month": 7,
        "temperature": {
          "min": 16.08,
          "max": 24.85
        },
        "sun": {
          "sunrise": 366,
          "sunset": 1307,
          "daylight": 941
        }
      },
      {
        "month": 8,
        "temperature": {
          "min": 16,
          "max": 26.44
        },
        "sun": {
          "sunrise": 406,
          "sunset": 1264,
          "daylight": 858
        }
      },
      {
        "month": 9,
        "temperature": {
          "min": 14.72,
          "max": 23.41
        },
        "sun": {
          "sunrise": 449,
          "sunset": 1203,
          "daylight": 754
        }
      },
      {
        "month": 10,
        "temperature": {
          "min": 8.41,
          "max": 15.22
        },
        "sun": {
          "sunrise": 489,
          "sunset": 1136,
          "daylight": 647
        }
      },
      {
        "month": 11,
        "temperature": {
          "min": 5.54,
          "max": 10.07
        },
        "sun": {
          "sunrise": 481,
          "sunset": 1032,
          "daylight": 551
        }
      },
      {
        "month": 12,
        "temperature": {
          "min": 2.55,
          "max": 8.26
        },
        "sun": {
          "sunrise": 517,
          "sunset": 1017,
          "daylight": 500
        }
      }
    ],
    "textual": {
      "title": "Weather",
      "sections": [
        {
          "id": "TEMPERATURES",
          "body": [
            "Paris has the same average temperature as London. Warmest month is August with 26°C and coldest January with 8°C."
          ]
        },
        {
          "id": "SUNLIGHT",
          "body": [
            "Sunrise is happening on average at 07:19, while sunset at 19:33. Average daylight is 12h 14min, which is 1 minute shorter than in London."
          ]
        }
      ]
    }
  },
  "publicTransportation": {
    "providers": [
      {
        "name": {
          "full": "Régie Autonome des Transports Parisiens",
          "short": "RATP"
        },
        "logo": {
          "png": "https://s3.amazonaws.com/basetrip/api/v3/public-transportation/fr-paris-ratp.png",
          "svg": "https://s3.amazonaws.com/basetrip/api/v3/public-transportation/fr-paris-ratp.svg"
        },
        "website": {
          "url": "https://www.ratp.fr",
          "languages": [
            "fra",
            "eng"
          ]
        },
        "modes": [
          {
            "type": "METRO",
            "timetable": "https://www.ratp.fr/en/horaires",
            "map": "https://www.ratp.fr/en/plans-lignes/plan-metro"
          },
          {
            "type": "TRAIN",
            "name": "RER",
            "timetable": "https://www.ratp.fr/en/horaires",
            "map": "https://www.ratp.fr/en/plans-lignes/plan-rer-et-transiliens"
          },
          {
            "type": "BUS",
            "timetable": "https://www.ratp.fr/en/horaires",
            "map": "https://www.ratp.fr/en/plans-lignes/plan-des-bus"
          },
          {
            "type": "TRAM",
            "timetable": "https://www.ratp.fr/en/horaires",
            "map": "https://www.ratp.fr/en/plans-lignes"
          }
        ],
        "tickets": {
          "prices": [
            {
              "type": "SINGLE",
              "price": {
                "currency": "EUR",
                "amount": 1.9,
                "amountInteger": 190,
                "displayAs": "€1.90"
              }
            },
            {
              "type": "MONTHLY",
              "price": {
                "currency": "EUR",
                "amount": 75,
                "amountInteger": 7500,
                "displayAs": "€75.00"
              }
            }
          ]
        }
      }
    ],
    "thirdPartyApps": [
      {
        "id": "TRANSIT",
        "name": "Transit",
        "link": "https://transitapp.com/region/paris"
      },
      {
        "id": "CITYMAPPER",
        "name": "Citymapper",
        "link": "https://citymapper.com/paris"
      },
      {
        "id": "MOOVIT",
        "name": "Moovit",
        "link": "https://moovit.com/?metroId=662"
      },
      {
        "id": "GOOGLE_TRANSIT",
        "name": "Google Transit (Maps)",
        "link": "https://maps.google.com"
      }
    ],
    "textual": {
      "title": "Public transportation",
      "sections": [
        {
          "id": "MODES",
          "body": [
            "Metro, bus, tram & train"
          ]
        },
        {
          "id": "SUMMARY",
          "body": [
            "There are metro, bus, tram & train lines available in Paris which are provided by RATP (Régie Autonome des Transports Parisiens)."
          ]
        },
        {
          "id": "TICKETS",
          "body": [
            "Single ticket costs €1.90 (£1.66) while 30-day pass costs €75.00 (£65.57)."
          ]
        },
        {
          "id": "APPS",
          "body": [
            "Alongside official apps, transit routes are also available via Transit, Citymapper, Moovit & Google Transit (Maps)."
          ]
        }
      ]
    }
  },
  "rideSharing": {
    "services": [
      {
        "name": "UBER",
        "website": "https://www.uber.com"
      },
      {
        "name": "TAXIFY",
        "website": "https://taxify.eu"
      }
    ],
    "textual": {
      "title": "Ride sharing",
      "sections": [
        {
          "id": "SERVICES",
          "body": [
            "Uber & Taxify"
          ]
        },
        {
          "id": "SUMMARY",
          "body": [
            "Uber & Taxify are the most popular ride sharing services in Paris."
          ]
        }
      ]
    }
  }
}