gabrielmoura/laravel-cep

A simple Laravel package to get CEP information

1.0 2023-12-09 17:57 UTC

This package is auto-updated.

Last update: 2024-04-09 18:51:29 UTC


README

A simple Laravel package to get CEP information

Latest Stable Version License

Providers

Configuration

If not defined, ViaCep will be used.

// config/services.php
   'cep'=>[
        'endpoint' => \Gabrielmoura\LaravelCep\EndpointOption::VIACEP,
    ]

Consider installing illuminate/redis for automatic caching.

Usage

Container

use Gabrielmoura\LaravelCep\CepService;
app(CepService::class)->find(cep:'01001000',cached: true);

Facade

use Gabrielmoura\LaravelCep\Cep;
Cep::find('01001000',cached: true);

Compatibility

  • Laravel 10.x