{"id":42962028,"url":"https://github.com/blancohugo/correios","last_synced_at":"2026-01-30T23:19:28.471Z","repository":{"id":62495067,"uuid":"148066581","full_name":"blancohugo/correios","owner":"blancohugo","description":"A service for fetching data from an address from a provided zip code.","archived":false,"fork":false,"pushed_at":"2018-09-25T20:23:02.000Z","size":22,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-11-08T12:46:30.609Z","etag":null,"topics":["cep","correios","correios-cep","php","zipcode"],"latest_commit_sha":null,"homepage":"","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/blancohugo.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-09-09T21:17:53.000Z","updated_at":"2019-08-22T16:22:13.000Z","dependencies_parsed_at":"2022-11-02T11:45:29.564Z","dependency_job_id":null,"html_url":"https://github.com/blancohugo/correios","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/blancohugo/correios","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blancohugo%2Fcorreios","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blancohugo%2Fcorreios/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blancohugo%2Fcorreios/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blancohugo%2Fcorreios/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/blancohugo","download_url":"https://codeload.github.com/blancohugo/correios/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blancohugo%2Fcorreios/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28922708,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-30T22:32:35.345Z","status":"ssl_error","status_checked_at":"2026-01-30T22:32:31.927Z","response_time":66,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: 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":["cep","correios","correios-cep","php","zipcode"],"created_at":"2026-01-30T23:19:27.786Z","updated_at":"2026-01-30T23:19:28.461Z","avatar_url":"https://github.com/blancohugo.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Correios zip code query with PHP\n\n[![Latest version][icon-packagist]][link-packagist]\n[![CircleCI][icon-circleci]][link-circleci]\n[![Code Coverage][icon-codecov]][link-codecov]\n[![Download count][icon-downloads]][link-packagist]\n\nA service for fetching data from an address from a provided zip code.\n\n## Installation\n\n``` bash\n$ composer require blancohugo/correios\n```\n\n## How-to\n\nSee the example below of how to implement a search for address data:\n\n``` php\n\u003c?php\n\nrequire 'vendor/autoload.php';\n\nuse BlancoHugo\\Correios\\Zipcode;\nuse BlancoHugo\\Correios\\Client;\nuse BlancoHugo\\Correios\\Exception;\n\n$client = new Client();\n$address = $client-\u003equery(new Zipcode('01311-929'));\n\n```\n\nThe client class uses exceptions for data treatments. Make sure your code will have a treatment for the following situations:\n\n``` php\n\u003c?php\n\ntry {\n    $address = $client-\u003equery(new Zipcode('01311-929'));\n} catch (Exception\\InvalidZipcodeException $e) {\n    // Invalid zipcode\n} catch (Exception\\ZipcodeNotFoundException $e) {\n    // Address data not found\n} catch (Exception\\UnexpectedResponseException $e) {\n    // Unexpected response from SIGEP\n}\n\n```\n\n## Contributing\n\nSee how to [CONTRIBUTE](https://github.com/blancohugo/correios/blob/master/CONTRIBUTING.md) to this project.\n\n[icon-packagist]: https://img.shields.io/packagist/v/blancohugo/correios.svg?style=flat-square\n[icon-circleci]: https://img.shields.io/circleci/project/github/blancohugo/correios.svg?style=flat-square\n[icon-codecov]: https://img.shields.io/codecov/c/github/blancohugo/correios.svg?style=flat-square\n[icon-downloads]: https://img.shields.io/packagist/dt/blancohugo/correios.svg?style=flat-square\n\n[link-packagist]: https://packagist.org/packages/blancohugo/correios\n[link-circleci]: https://circleci.com/gh/blancohugo/correios\n[link-codecov]: https://codecov.io/gh/blancohugo/correios","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fblancohugo%2Fcorreios","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fblancohugo%2Fcorreios","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fblancohugo%2Fcorreios/lists"}