PHPackages                             grmule/php-ziptastic - 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. grmule/php-ziptastic

AbandonedArchivedLibrary[API Development](/categories/api)

grmule/php-ziptastic
====================

A simple class for accessing the Ziptastic API (https://www.getziptastic.com/)

1.0.0(11y ago)1421MITPHPPHP &gt;=5.3.0

Since May 5Pushed 9y ago1 watchersCompare

[ Source](https://github.com/GRMule/PHP-Ziptastic)[ Packagist](https://packagist.org/packages/grmule/php-ziptastic)[ Docs](https://github.com/GRMule/PHP-Ziptastic)[ RSS](/packages/grmule-php-ziptastic/feed)WikiDiscussions master Synced 1w ago

READMEChangelogDependenciesVersions (2)Used By (0)

PHP-Ziptastic
=============

[](#php-ziptastic)

A simple PHP class used to access the Ziptastic API.

Sample usage:

```
$zt = new PHPZiptastic\Ziptastic(49504);

print $zt->city; // Grand Rapids

print $zt->lookup(34231)->city; // Sarasota

print $zt->lookup(44870); // Bloomingville, OH

print json_encode($zt); // {"city":"Bloomingville","state":"OH","zip":"44870"}
```

Errors and Exceptions
=====================

[](#errors-and-exceptions)

By default, errors (zip not found, malformed zip passed) will place a message in the $error property, and return a self-reference. This looks like:

```
print $zt->lookup(12344)->city; // null
print $zt->error; // Invalid zip code
```

If you would like to catch an exception instead, pass TRUE as a second constructor parameter:

```
$zt = new Ziptastic(null, true);
$zt->lookup(12344); // exception thrown here
```

OR

```
$zt = new Ziptastic(12344, true); // exception thrown here
```

For all errors, the exception throw is the base PHP Exception class.

Installation
============

[](#installation)

Include Ziptastic.php or install the composer package.

Ziptastic
=========

[](#ziptastic)

Ziptastic is a simple API that allows people to ask which Country,State and City are associated with a Zip Code.

More info at

Many thanks to ElevenBaseTwo () for shortening our forms!

###  Health Score

27

—

LowBetter than 47% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity10

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity58

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 92.3% 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.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

4053d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/056b7b35e35fb5c250f3b7f09e8371668bb1d8d265c8adaf187724cf3da7ec76?d=identicon)[GRMule](/maintainers/GRMule)

---

Top Contributors

[![GRMule](https://avatars.githubusercontent.com/u/2015304?v=4)](https://github.com/GRMule "GRMule (12 commits)")[![daspecster](https://avatars.githubusercontent.com/u/192456?v=4)](https://github.com/daspecster "daspecster (1 commits)")

---

Tags

postalzipziptastic

### Embed Badge

![Health badge](/badges/grmule-php-ziptastic/health.svg)

```
[![Health](https://phpackages.com/badges/grmule-php-ziptastic/health.svg)](https://phpackages.com/packages/grmule-php-ziptastic)
```

###  Alternatives

[facebook/php-business-sdk

PHP SDK for Facebook Business

90923.5M35](/packages/facebook-php-business-sdk)[hubspot/api-client

Hubspot API client

24015.5M18](/packages/hubspot-api-client)[botman/driver-telegram

Telegram driver for BotMan

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

PHPackages © 2026

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