{"id":18927842,"url":"https://github.com/0xabdulkhaliq/weatherwise-backend","last_synced_at":"2026-05-18T00:08:50.822Z","repository":{"id":194681249,"uuid":"686368442","full_name":"0xabdulkhaliq/weatherwise-backend","owner":"0xabdulkhaliq","description":"Express.js powered backend for WeatherWise's API protection.","archived":false,"fork":false,"pushed_at":"2023-09-13T15:13:58.000Z","size":26,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-07-21T12:29:02.091Z","etag":null,"topics":["api","backend","express","js","weather"],"latest_commit_sha":null,"homepage":"https://weatherwise-backend.vercel.app","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/0xabdulkhaliq.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2023-09-02T14:58:20.000Z","updated_at":"2023-09-14T01:43:49.000Z","dependencies_parsed_at":"2023-09-24T05:09:15.446Z","dependency_job_id":null,"html_url":"https://github.com/0xabdulkhaliq/weatherwise-backend","commit_stats":{"total_commits":12,"total_committers":1,"mean_commits":12.0,"dds":0.0,"last_synced_commit":"78a90f4494b3dcb06b5762676bbea47d709fb3cc"},"previous_names":["0xabdulkhalid/weatherwise-backend","0xabdulkhaliq/weatherwise-backend"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/0xabdulkhaliq/weatherwise-backend","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0xabdulkhaliq%2Fweatherwise-backend","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0xabdulkhaliq%2Fweatherwise-backend/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0xabdulkhaliq%2Fweatherwise-backend/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0xabdulkhaliq%2Fweatherwise-backend/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/0xabdulkhaliq","download_url":"https://codeload.github.com/0xabdulkhaliq/weatherwise-backend/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0xabdulkhaliq%2Fweatherwise-backend/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33160168,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-17T22:39:12.733Z","status":"ssl_error","status_checked_at":"2026-05-17T22:39:10.741Z","response_time":107,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["api","backend","express","js","weather"],"created_at":"2024-11-08T11:21:01.623Z","updated_at":"2026-05-18T00:08:50.807Z","avatar_url":"https://github.com/0xabdulkhaliq.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cbr\u003e\n\u003cdiv align=center\u003e\n\u003cimg src=\"./images/logo.svg\" alt=\"WeatherWise Backend\" width=\"350\"\u003e\n\u003c/div\u003e\n\u003cbr\u003e\n\n## Description\n\n- The WeatherWise Backend is a critical component of the WeatherWise project. It serves as the secure gateway for fetching real-time weather data from external APIs while protecting sensitive API keys. \n\n- The WeatherWise Backend utilizes two weather APIs to provide comprehensive weather data:\n\n    - [WeatherAPI](https://www.weatherapi.com/) : WeatherAPI provides essential weather information and is a key component of the WeatherWise Backend.\n\n    - [Open-Meteo](https://open-meteo.com/): Open-Meteo is another weather API integrated into the backend, offering additional weather data and forecasts.\n\n    - Both APIs work in conjunction to ensure that WeatherWise delivers accurate and up-to-date weather information to users.\n\n- This Express.js-based backend ensures data security and provides reliable weather information to the WeatherWise application.\n\n## Features\n\n- **API Key Protection**: The backend safeguards your API key, preventing unauthorized access and ensuring the confidentiality of sensitive data.\n\n- **Rate Limiting**: Utilizes Express.js rate limiting middleware to control the number of API requests, preventing abuse and ensuring fair usage.\n\n- **CORS Configuration**: Configures Cross-Origin Resource Sharing (CORS) to allow access from specified origins, enhancing the accessibility of the API.\n\n- **Weather Data Retrieval**: Fetches weather data from external APIs, combines responses, and serves up-to-date weather information to the WeatherWise application.\n\n## Getting Started\n\nTo set up the WeatherWise Backend locally, follow these steps:\n\n1. Clone the GitHub repository to your local machine:\n\n   ```bash\n   git clone https://github.com/0xabdulkhalid/weatherwise-backend.git\n   ```\n\n2. Navigate to the backend's directory:\n\n   ```bash\n   cd weatherwise-backend\n   ```\n\n3. Install the backend's dependencies using npm:\n\n   ```bash\n   npm install\n   ```\n\n4. Create a .env file in the backend's root directory and add your Weather API key. If you don't have an API key yet, you can obtain one by signing up at [weatherapi.com](https://www.weatherapi.com):\n\n   ```env\n   API_KEY=your_api_key_here\n   ```\n\n5. Start the local backend server:\n\n   ```bash\n   npm start\n   ```\n\nNow, the WeatherWise Backend is running locally on your machine.\n\n## Usage\n\n- You can access the backend application by opening your web browser and navigating to http://localhost:7417\n- Be sure to modify the CORS Configuration so that backend won't return `Forbidden`.\n- Additionally you need to modify backend api url on Weatherwise Application's API Module.\n- Build your changes for WeatherWise, now you test the application by visiting `index.html` file on `dist` directory.\n\n## API Endpoints\n\n- **GET /weather**: Retrieves real-time weather data based on latitude and longitude parameters. Example:\n\n  ```http\n  GET /weather?latitude=your_latitude\u0026longitude=your_longitude\n  ```\n\n## CORS Configuration\n\n- By default, the backend only allows requests from the Weatherwise Application's origin\n\n- You can modify the `allowedOrigins` array in the code to add or restrict origins according to your project's requirements.\n\n## Rate Limiting\n\n- The backend enforces rate limiting with a maximum of 1 request per second. \n- You can adjust the `max` and `windowMs` parameters in the `rateLimit` middleware to suit your needs.\n\n## License\n\n- This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n\n## Let's Connect 👋\n\n\u003cdiv align=center\u003e\n\n  \u003ca href=\"https://linkedin.com/in/0xabdulkhalid\" \u003e\n    \u003cimg src=\"https://img.shields.io/badge/linkedin%20Profile-%2300acee.svg?color=405DE6\u0026style=for-the-badge\u0026logo=linkedin\u0026logoColor=white\" alt=\"Linkedin Profile\"\u003e\n  \u003c/a\u003e\u0026nbsp;\u0026nbsp;\n\n  \u003ca href=\"mailto:0xabdulkhalid@gmail.com\" target=\"_blank\"\u003e\n    \u003cimg src=\"https://img.shields.io/badge/gmail-%23EA4335.svg?style=for-the-badge\u0026logo=gmail\u0026logoColor=white\" alt=mail/\u003e\n  \u003c/a\u003e\u0026nbsp;\u0026nbsp;\n\n  \u003ca href=\"https://www.github.com/0xabdulkhalid/\" \u003e\n    \u003cimg src=\"https://img.shields.io/badge/Github%20Profile-131313?style=for-the-badge\u0026logo=github\u0026logoColor=white\" alt=\"Github Profile\"\u003e\n  \u003c/a\u003e\n\n\u003c/div\u003e\n\n\u003cbr\u003e","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F0xabdulkhaliq%2Fweatherwise-backend","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F0xabdulkhaliq%2Fweatherwise-backend","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F0xabdulkhaliq%2Fweatherwise-backend/lists"}