diff --git a/composer.json b/composer.json index c8e8767..c107d0d 100644 --- a/composer.json +++ b/composer.json @@ -1,6 +1,6 @@ { "name": "simplesvet/enotas", - "version": "2.3", + "version": "2.4", "description": "eNotasGW API", "type": "package", "require": { diff --git a/src/empresaApi.php b/src/empresaApi.php index fc08675..d4fe247 100644 --- a/src/empresaApi.php +++ b/src/empresaApi.php @@ -28,18 +28,18 @@ public function consultar($idEmpresa) } /** - * Listar empresa por sua Razão Social + * Listar empresa por CNPJ * - * @param string $razaoSocial + * @param string $cnpj */ - public function consultarPorRazaoSocial($razaoSocial) + public function consultarPorCnpj($cnpj) { return $this->callOperation(array( 'method' => 'GET', - 'path' => '/empresas?pageNumber=0&pageSize=1&searchBy=Razao_Social&searchTerm={razaoSocial}', + 'path' => '/empresas?pageNumber=0&pageSize=1&searchTerm={cnpj}', 'parameters' => array( 'path' => array( - 'razaoSocial' => $razaoSocial + 'cnpj' => $cnpj ) ) ));