kenowlee/oxi-brasil-api

与巴西Api交互的简单方式。

v1.0.3 2021-09-25 19:22 UTC

This package is auto-updated.

Last update: 2024-09-26 02:18:59 UTC


README

巴西API消费类

与巴西Api交互的简单方式。

做这个的人真是天才,所有东西都在一个地方!

StyleCI

去看看网站吧

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

(new Brasil\Api)->banco('341');

//resultado
Array
(
    [ispb] => 60701190
    [name] => ITAÚ UNIBANCO S.A.
    [code] => 341
    [fullName] => ITAÚ UNIBANCO S.A.
)

非常容易使用,看看吧!

通过composer安装

$ composer require kenowlee/oxi-brasil-api

想要查看所有巴西银行的列表,看看你是怎么做的!

(new Brasil\Api)->bancos();

//resultado
Array
(
    [0] => Array
        (
            [ispb] => 00000000
            [name] => BCO DO BRASIL S.A.
            [code] => 1
            [fullName] => Banco do Brasil S.A.
        )

    [1] => Array
        (
            [ispb] => 00000208
            [name] => BRB - BCO DE BRASILIA S.A.
            [code] => 70
            [fullName] => BRB - BANCO DE BRASILIA S.A.
        )
...

哎呀,真好...

现在看看,你是怎么查看银行详细信息的,你只需要在函数中输入银行编号,就可以了

(new Brasil\Api)->banco('341');

//resultado
Array
(
    [ispb] => 60701190
    [name] => ITAÚ UNIBANCO S.A.
    [code] => 341
    [fullName] => ITAÚ UNIBANCO S.A.
)

很简单!

这些人不浪费时间,看看这里,看看你是如何查看所有类型的车辆品牌的。

//Só as marcas das Motoca
(new Brasil\Api)->motos();

//Só as Naves
(new Brasil\Api)->carros();

//Aqui só os gigantes hein!
(new Brasil\Api)->caminhoes();

//resultado das Motoca
Array
(
    [0] => Array
        (
            [nome] => ADLY
            [valor] => 60
        )

    [1] => Array
        (
            [nome] => AGRALE
            [valor] => 61
        )

    [2] => Array
        (
            [nome] => APRILIA
            [valor] => 62
        )
...

哇,太多了!

这个CEP功能真是太棒了,因为这些家伙在多个提供商上进行查询。

(new Brasil\Api)->cep('18013900');

Array
(
    [cep] => 18013900
    [state] => SP
    [city] => Sorocaba
    [neighborhood] => Jardim do Paço
    [street] => Avenida Engenheiro Carlos Reinaldo Mendes
    [service] => viacep
    [location] => Array
        (
            [type] => Point
            [coordinates] => Array
                (
                    [longitude] => -47.428788
                    [latitude] => -23.4858059
                )
        )
)

哎呀,玛丽亚...看看其他的东西吧!

全国节假日

(new Brasil\Api)->feriados('2021');

CNPJ

(new Brasil\Api)->cnpj('12345678901234');

州列表

(new Brasil\Api)->estados();

州详细信息

(new Brasil\Api)->estado('SP');

按州列表市

(new Brasil\Api)->municipios('SP');

FIPE参考表

(new Brasil\Api)->fipe('SP');

FIPE车辆价格表

(new Brasil\Api)->precofipe('codigo-fipe');

按DDD返回州和城市列表

(new Brasil\Api)->ddd('11');

祝你好运,使用愉快!

;)