PHPackages                             spacedealer/yii2-geonames - 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. [HTTP &amp; Networking](/categories/http)
4. /
5. spacedealer/yii2-geonames

ActiveYii2-extension[HTTP &amp; Networking](/categories/http)

spacedealer/yii2-geonames
=========================

Yii2 extension for geonames.org webservice api

0.2.0(11y ago)16383BSD-3-ClausePHP

Since Dec 3Pushed 11y ago4 watchersCompare

[ Source](https://github.com/spacedealer/yii2-geonames)[ Packagist](https://packagist.org/packages/spacedealer/yii2-geonames)[ Docs](https://github.com/spacedealer/yii2-geonames)[ RSS](/packages/spacedealer-yii2-geonames/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (3)Versions (3)Used By (0)

Geonames API client extension for Yii2
======================================

[](#geonames-api-client-extension-for-yii2)

**Attention**: Please do not use in production environments. It‘s WIP.

This is a [Geonames API](http://www.geonames.org/export/web-services.html) client extension for the Yii2 Framework. It wraps around the [geonames-api php library](https://github.com/spacedealer/geonames-api).

[![Build Status](https://camo.githubusercontent.com/086e43b3bf72c61138ff07266d876cbf52670445e2381814e05856eab2f69604/68747470733a2f2f7472617669732d63692e6f72672f73706163656465616c65722f796969322d67656f6e616d65732e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/spacedealer/yii2-geonames)[![SensioLabsInsight](https://camo.githubusercontent.com/d1a94dd2c26f46e45f4f13c916f246d3298183ef5211b5ad023a75a626f509c7/68747470733a2f2f696e73696768742e73656e73696f6c6162732e636f6d2f70726f6a656374732f38386161363664312d383262622d346234642d386239612d3036353832313164303665642f6d696e692e706e67)](https://insight.sensiolabs.com/projects/88aa66d1-82bb-4b4d-8b9a-0658211d06ed)[![Dependency Status](https://camo.githubusercontent.com/a0bc158b3cbf61b15dcade9b69bf03f6068af046b7ab531c208de8fdeaf2a8e6/68747470733a2f2f7777772e76657273696f6e6579652e636f6d2f757365722f70726f6a656374732f3534376565613763383637346134643233333030303161612f62616467652e7376673f7374796c653d666c6174)](https://www.versioneye.com/user/projects/547eea7c8674a4d2330001aa)

Requirements
------------

[](#requirements)

- php &gt;= 5.4
- spacedealer/geonames-api 0.2

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

[](#installation)

The preferred way to install this extension is through [composer](http://getcomposer.org/download/).

Either run

```
php composer.phar require --prefer-dist spacedealer/yii2-geonames "*"

```

or add

```
"spacedealer/yii2-geonames": "*"

```

to the require section of your `composer.json` file.

Usage
-----

[](#usage)

Once the extension is installed, simply modify your application components configuration as follows:

```
'geonames' => [
	'class' => 'spacedealer\geonames\Geonames',
	'username' => 'your_username',
	'language' => 'de',
],
```

Use within your Yii2 application logic:

```
$geonames = \Yii::$app->get('geonames')->getClient();
$response = $geonames->postalCodeSearch([
	'country' => 'de',
	'postalcode' => '10997',
]);
```

Todos
-----

[](#todos)

- add unit tests

Resources
---------

[](#resources)

- [Source](https://github.com/spacedealer/yii2-geonames)
- [Issues](https://github.com/spacedealer/yii2-geonames/issues)

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity17

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity54

Maturing project, gaining track record

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.

###  Release Activity

Cadence

Every ~63 days

Total

2

Last Release

4116d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/b53d403fce38ae29e4d8368820988c0e4c936193655d95dd7e06b533099a1bee?d=identicon)[dirx](/maintainers/dirx)

---

Tags

apiclientrestGuzzleyii2extensiongeonames

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/spacedealer-yii2-geonames/health.svg)

```
[![Health](https://phpackages.com/badges/spacedealer-yii2-geonames/health.svg)](https://phpackages.com/packages/spacedealer-yii2-geonames)
```

###  Alternatives

[hiqdev/yii2-hiart

ActiveRecord for API

5951.8k3](/packages/hiqdev-yii2-hiart)[e-moe/guzzle6-bundle

Integrates Guzzle 6 into your Symfony application

11259.2k](/packages/e-moe-guzzle6-bundle)

PHPackages © 2026

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