PHPackages                             modulor/weather - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. modulor/weather

ActiveLibrary[API Development](/categories/api)

modulor/weather
===============

get weather from openweathermap api

06PHP

Since Dec 13Pushed 9y ago1 watchersCompare

[ Source](https://github.com/modulor/weather)[ Packagist](https://packagist.org/packages/modulor/weather)[ RSS](/packages/modulor-weather/feed)WikiDiscussions master Synced yesterday

READMEChangelogDependenciesVersions (1)Used By (0)

OpenWeatherMap PHP Library
==========================

[](#openweathermap-php-library)

Basic API usage from [openweathermap.org](http://openweathermap.org)

Installation
------------

[](#installation)

**via [Composer](http://getcomposer.org/):**

Create or add the following to composer.json in your project root:

```
{
    "repositories": [
        {
            "type": "vcs",
            "url": "https://github.com/modulor/weather"
        }
    ],
    "require": {
        "modulor/weather": "dev-master"
    }
}
```

run **composer install**

Example
-------

[](#example)

Get weather by city name

```
require_once("path/to/vendor/autoload.php");

WeatherAPI\Configs::setApiKey('your_api_key');

$searchWeather = new WeatherAPI\Current\Search();

$searchWeather->setQueryParams(array(
  'q' => 'london'
));

print_r($searchWeather->execute());
```

Get weather by geographic coordinates

```
require_once("path/to/vendor/autoload.php");

WeatherAPI\Configs::setApiKey('your_api_key');

$searchWeather = new WeatherAPI\Current\Search();

$searchWeather->setQueryParams(array(
  'lat' => '-22.0622478',
  'lon' => '-44.0444834'
));

print_r($searchWeather->execute());
```

###  Health Score

20

—

LowBetter than 13% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/3484504?v=4)[Mario](/maintainers/modulor)[@modulor](https://github.com/modulor)

---

Top Contributors

[![modulor](https://avatars.githubusercontent.com/u/3484504?v=4)](https://github.com/modulor "modulor (10 commits)")

### Embed Badge

![Health badge](/badges/modulor-weather/health.svg)

```
[![Health](https://phpackages.com/badges/modulor-weather/health.svg)](https://phpackages.com/packages/modulor-weather)
```

###  Alternatives

[exsyst/swagger

A php library to manipulate Swagger specifications

35916.4M7](/packages/exsyst-swagger)[hubspot/api-client

Hubspot API client

24016.2M18](/packages/hubspot-api-client)[pocketmine/bedrock-protocol

An implementation of the Minecraft: Bedrock Edition protocol in PHP

172437.8k11](/packages/pocketmine-bedrock-protocol)[botman/driver-telegram

Telegram driver for BotMan

93459.5k6](/packages/botman-driver-telegram)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
