PHPackages                             inigo-aldama/inmovilla-api-client - 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. [API Development](/categories/api)
4. /
5. inigo-aldama/inmovilla-api-client

ActiveLibrary[API Development](/categories/api)

inigo-aldama/inmovilla-api-client
=================================

A PHP library to interact with the Inmovilla API

v1.0.0(1y ago)120212MITPHPPHP ^7.4 || ^8.0

Since Dec 19Pushed 1y ago1 watchersCompare

[ Source](https://github.com/inigo-aldama/inmovilla-api-client)[ Packagist](https://packagist.org/packages/inigo-aldama/inmovilla-api-client)[ Docs](https://github.com/inigo-aldama/inmovilla-api-client)[ RSS](/packages/inigo-aldama-inmovilla-api-client/feed)WikiDiscussions main Synced today

READMEChangelogDependencies (6)Versions (3)Used By (2)

Inmovilla API Client (Unofficial)
=================================

[](#inmovilla-api-client-unofficial)

![Latest Version](https://camo.githubusercontent.com/4f7e0d0b2eb3de8c977c19f21c7250bee9dcbaef07d742736035565ed3a1f2e6/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f76657273696f6e2d312e302e302d626c7565)![PHP](https://camo.githubusercontent.com/39f74b306b25933f9e9dd63e6d2403f80b6496881143a3fcf48583a7e45f854b/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f7068702d253545372e34253230253743253743253230253545382e302d626c7565)[![License](https://camo.githubusercontent.com/f8df3091bbe1149f398a5369b2c39e896766f9f6efba3477c63e9b4aa940ef14/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d677265656e)](LICENSE)

`inmovilla-api-client` is a PHP library that provides an interface for interacting with the Inmovilla real estate API. It simplifies requests, pagination, and data handling, allowing developers to focus on building applications.

> **Note:** This project is not affiliated with, endorsed by, or maintained by Inmovilla.

---

Features
--------

[](#features)

- **API Configuration**: Easy setup using `.ini` files or arrays.
- **Request Handling**: Supports batch requests and flexible filtering.
- **DTOs**: Data transfer objects for working with API data in a structured way.
- **Pagination**: Handles paginated responses seamlessly.
- **PSR Compliance**: Built with PSR-7, PSR-11, and PSR-18 standards.

---

Requirements
------------

[](#requirements)

- **PHP**: 7.4 or higher.
- **Composer**: For dependency management.
- Required PHP extensions:
    - `ext-json`
    - `ext-curl`

---

Installation
------------

[](#installation)

Install the package using Composer:

```
composer require inigo-aldama/inmovilla-api-client
```

---

Configuration
-------------

[](#configuration)

### Using an `.ini` File

[](#using-an-ini-file)

Create a configuration file (e.g., `config/api.ini`) with the following content:

```
api_url = "https://api.inmovilla.com/v1"
domain = "example.com"
agency = "my-agency"
password = "my-password"
language = 1
```

Load the configuration with:

```
use Inmovilla\ApiClient\ApiClientConfig;

$config = ApiClientConfig::fromIniFile('config/api.ini');
```

### Using an Array

[](#using-an-array)

Alternatively, use an array for configuration:

```
$config = ApiClientConfig::fromArray([
    'AGENCY' => 'my-agency',
    'PASSWORD' => 'my-password',
    'LANGUAGE' => 1,
    'API_URL' => 'https://api.inmovilla.com/v1',
    'DOMAIN' => 'example.com',
]);
```

---

Example: Complete Flow
----------------------

[](#example-complete-flow)

This example demonstrates how to retrieve cities, their zones, and properties associated with those zones, as well as fetch detailed property information.

```
