{"id":21026278,"url":"https://github.com/detain/zip-zapper","last_synced_at":"2026-03-03T02:31:42.421Z","repository":{"id":45194825,"uuid":"85762801","full_name":"detain/zip-zapper","owner":"detain","description":"Validates Zip / Postal type codes by country","archived":false,"fork":false,"pushed_at":"2023-04-11T15:52:10.000Z","size":133,"stargazers_count":7,"open_issues_count":2,"forks_count":4,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-12-17T03:26:09.711Z","etag":null,"topics":["postal-code","validation","zipcode"],"latest_commit_sha":null,"homepage":null,"language":"PHP","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/detain.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,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-03-21T23:10:52.000Z","updated_at":"2024-10-07T16:53:30.000Z","dependencies_parsed_at":"2024-11-19T11:55:10.240Z","dependency_job_id":"df1897ed-b086-4b95-8d28-ed3f05c2ba32","html_url":"https://github.com/detain/zip-zapper","commit_stats":{"total_commits":136,"total_committers":4,"mean_commits":34.0,"dds":0.05147058823529416,"last_synced_commit":"864f7259feb9c092c244c1a07371638ae3536674"},"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/detain/zip-zapper","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/detain%2Fzip-zapper","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/detain%2Fzip-zapper/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/detain%2Fzip-zapper/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/detain%2Fzip-zapper/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/detain","download_url":"https://codeload.github.com/detain/zip-zapper/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/detain%2Fzip-zapper/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30030829,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-03T00:31:48.536Z","status":"online","status_checked_at":"2026-03-03T02:00:07.650Z","response_time":61,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["postal-code","validation","zipcode"],"created_at":"2024-11-19T11:44:04.068Z","updated_at":"2026-03-03T02:31:42.389Z","avatar_url":"https://github.com/detain.png","language":"PHP","readme":"# Zip Zapper\n\nValidates Zip / Postal type codes by country with some features \n\n[![Latest Stable Version](https://poser.pugx.org/detain/zip-zapper/version)](https://packagist.org/packages/detain/zip-zapper)\n[![Total Downloads](https://poser.pugx.org/detain/zip-zapper/downloads)](https://packagist.org/packages/detain/zip-zapper)\n[![Latest Unstable Version](https://poser.pugx.org/detain/zip-zapper/v/unstable)](//packagist.org/packages/detain/zip-zapper)\n[![License](https://poser.pugx.org/detain/zip-zapper/license)](https://packagist.org/packages/detain/zip-zapper)\n[![Monthly Downloads](https://poser.pugx.org/detain/zip-zapper/d/monthly)](https://packagist.org/packages/detain/zip-zapper)\n[![Daily Downloads](https://poser.pugx.org/detain/zip-zapper/d/daily)](https://packagist.org/packages/detain/zip-zapper)\n[![Reference Status](https://www.versioneye.com/php/detain:zip-zapper/reference_badge.svg?style=flat)](https://www.versioneye.com/php/detain:zip-zapper/references) \n[![Build Status](https://travis-ci.org/detain/zip-zapper.svg?branch=master)](https://travis-ci.org/detain/zip-zapper)\n[![Code Climate](https://codeclimate.com/github/detain/zip-zapper/badges/gpa.svg)](https://codeclimate.com/github/detain/zip-zapper) \n[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/detain/zip-zapper/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/detain/zip-zapper/?branch=master) \n[![Codacy Badge](https://api.codacy.com/project/badge/Grade/659523f63e16487ea71f6b763908d09e)](https://www.codacy.com/app/detain/zip-zapper)\n\n\n\n[Postal Systems by Country](https://en.wikipedia.org/wiki/Category:Postal_system)\u003cbr\u003e\n[DMOZ Post/Zip Code Info+DB](http://dmoztools.net/Reference/Directories/Address_and_Phone_Numbers/Postal_Codes/)\u003cbr\u003e\n[List of Postal Codes](https://en.wikipedia.org/wiki/List_of_postal_codes)\u003cbr\u003e\n\nBased on a similar project [sirprize/postal-code-validator](https://github.com/sirprize/postal-code-validator) but expanded on it adding over 100 new validations and updating ther others using mostly the Wikipedia postal codes list and some other features I needed in zip validation.\n\n## Installation\n\n    composer require detain/zip-zapper\n\n## Usage\n\n### Check If Country Is Supported\n\n    use Detain\\ZipZapper\\Validator;\n    \n    $validator = new Validator();\n    $validator-\u003ehasCountry('CH'); // returns true\n\n### Check If Postal Code Is Properly Formatted\n\n    use Detain\\ZipZapper\\Validator;\n    \n    $validator = new Validator();\n    $validator-\u003eisValid('CH', 'usjU87jsdf'); // returns false\n    $validator-\u003eisValid('CH', '3007'); // returns true\n\n### Get The Possible Formats For a Specific Country\n\n    use Detain\\ZipZapper\\Validator;\n    \n    $validator = new Validator();\n    $validator-\u003egetFormats('GB'); // returns array('@@## #@@', '@#@ #@@', '@@# #@@', '@@#@ #@@', '@## #@@', '@# #@@')\n\n## Formatting\n\n+ `#` = `0-9`\n+ `@` = `a-zA-Z`\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdetain%2Fzip-zapper","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdetain%2Fzip-zapper","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdetain%2Fzip-zapper/lists"}