PHPackages                             fernandovaller/indices-economicos - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. fernandovaller/indices-economicos

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

fernandovaller/indices-economicos
=================================

Obter automaticamente os últimos índices divulgados

v1.2(1y ago)228MITPHP

Since Oct 13Pushed 1y ago1 watchersCompare

[ Source](https://github.com/fernandovaller/indices-economicos)[ Packagist](https://packagist.org/packages/fernandovaller/indices-economicos)[ RSS](/packages/fernandovaller-indices-economicos/feed)WikiDiscussions master Synced today

READMEChangelogDependencies (1)Versions (4)Used By (0)

Índices Econômicos
==================

[](#índices-econômicos)

**Autor:** Fernando Valler
[Website](http://fernandovaller.com)

Este projeto automatiza a obtenção dos últimos índices econômicos divulgados, como:

- **IGP-M (FGV)**
- **INPC (IBGE)**
- **IPCA (IBGE)**
- **INCC-M (FGV)**

🚀 Introdução
------------

[](#-introdução)

Este projeto facilita o acesso aos principais índices econômicos diretamente via PHP, possibilitando o uso em diversos cenários, como dashboards, relatórios e análises financeiras.

### Requisitos

[](#requisitos)

- PHP 5.6+
- Composer

### 📦 Instalação

[](#-instalação)

1. Clone o repositório:

    ```
    git clone https://github.com/fernandovaller/indices-economicos.git
    ```
2. Navegue até o diretório do projeto:

    ```
    cd indices-economicos
    ```
3. Instale as dependências com o Composer:

    ```
    composer install
    ```

### 📚 Exemplo de Uso

[](#-exemplo-de-uso)

Abaixo está um exemplo básico de como utilizar o projeto para obter os índices econômicos:

```
require __DIR__ . '/vendor/autoload.php';

use App\Sinduscon\Indice;

// Criar uma nova instância para buscar os índices
$indice = new Indice();

// Obter todos os índices mais recentes como array
$dados = $indice->build()->all();

// Obter todos os índices mais recentes como JSON
$dados = $indice->build()->json();

// Obter um índice específico (ex: IGP-M)
$dados = $indice->build()->get('IGP-M(FGV)');

// Listar todos os índices disponíveis
$listaIndices = $indice->listIndiceAllowed();

// Limpar cache e obter os índices novamente
$dados = $indice->clearCache()->build()->json();
```

### 📊 Exemplo de Retorno

[](#-exemplo-de-retorno)

O retorno da API será semelhante ao exemplo abaixo:

```
{
  "IGP-M(FGV)": {
    "indice": "IGP-M(FGV)",
    "url": "https://sindusconpr.com.br/?pid=309",
    "data": {
      "date": "2020-04-01",
      "value": "778,101",
      "variation_month": "0,80",
      "variation_year": "2,50",
      "variation_twelve_months": "6,68"
    }
  }
}
```

### 🛠️ Contribuição

[](#️-contribuição)

Contribuições são bem-vindas! Se você encontrar algum problema ou tiver sugestões de melhorias, fique à vontade para abrir uma issue ou enviar um pull request.

### 📄 Licença

[](#-licença)

Este projeto está licenciado sob a [MIT License](LICENSE).

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance35

Infrequent updates — may be unmaintained

Popularity10

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity52

Maturing project, gaining track record

 Bus Factor1

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

Every ~532 days

Total

3

Last Release

607d ago

### Community

Maintainers

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

---

Top Contributors

[![fernandovaller](https://avatars.githubusercontent.com/u/5489549?v=4)](https://github.com/fernandovaller "fernandovaller (10 commits)")

### Embed Badge

![Health badge](/badges/fernandovaller-indices-economicos/health.svg)

```
[![Health](https://phpackages.com/badges/fernandovaller-indices-economicos/health.svg)](https://phpackages.com/packages/fernandovaller-indices-economicos)
```

###  Alternatives

[lullabot/amp

A set of useful classes and utilities to convert html to AMP html (See https://www.ampproject.org/)

3802.9M10](/packages/lullabot-amp)[platformsh/config-reader

Small helper to access Platform.sh environment variables

235.1M22](/packages/platformsh-config-reader)

PHPackages © 2026

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