A full-stack weather application built with Python (Flask) on the backend and HTML/CSS/JavaScript on the frontend.
This project fetches live weather data from OpenWeatherMap and exposes it through a custom REST API and GraphQL endpoint. The frontend communicates with the backend to display weather information.
GET /health
Response:
{ "status": "OK" }GET /weather?city=CityName
Response:
{
"city": "London",
"temperature": 11.5,
"humidity": 80,
"condition": "overcast clouds"
}- 400 — Missing city parameter
- 404 — City not found
- 502 — External API failure
POST /graphql
Example query:
query {
weather(city: "London") {
temperature
humidity
condition
}
}Simple HTML/CSS/JavaScript page that fetches weather data from the backend using the Fetch API.
- User types city name in the browser
- JavaScript sends GET request to /weather
- Flask backend calls OpenWeatherMap API
- Backend returns clean JSON response
- JavaScript displays data on the page
See the screenshots folder for additional examples including error handling and multiple cities.






