Download the PHP package homlity/sdk-metrocuadrado without Composer

On this page you can find all versions of the php package homlity/sdk-metrocuadrado. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package sdk-metrocuadrado

Homlity · para desarrolladores
homlity.com · Portal de desarrolladores

SDK PHP para Metrocuadrado

Packagist PHP

SDK PHP mantenido por Homlity para integrarse con la API de Metrocuadrado (PTEC Core), escrito sobre la documentación oficial.

Cubre los 19 endpoints publicados: autenticación, catálogos, agentes, sucursales, inmuebles y transacciones. Cero dependencias de runtime.

📚 Referencia completa de métodos, uno a uno, con para qué sirve cada uno y un ejemplo ejecutable: docs/referencia-metodos.md.

Requisitos

Instalación

Uso

Config::development(...) apunta al entorno de desarrollo de Metrocuadrado.

Qué hay implementado

Recurso Métodos
auth() · token() emisión, caché y renovación del JWT
catalogue() regions · cities · zones · sectors · neighborhoodsByCity · neighborhoodsBySector · neighborhood · searchNeighborhoods · businessTypes · realEstateTypes · amenities
agents() all · create · update
offices() all
realEstate() published · unpublished · listByStatus · find · publish · update · unpublish
transactions() find

Cada método, con firma, parámetros, excepciones y ejemplo, en docs/referencia-metodos.md. La tabla endpoint ↔ método está en docs/api-reference.md.

Autenticación

La API vive en dos hosts —el emisor de tokens y el de recursos— y no usa Authorization: Bearer: la API key va en x-api-key y el JWT en el header token. El token dura una hora; el SDK lo cachea, lo renueva 60 s antes de caducar y, ante un 401, lo renueva y reintenta la petición una vez.

Detalle en docs/autenticacion.md; ejemplo ejecutable en examples/autenticacion.php.

Operaciones asíncronas

Publicar, actualizar y despublicar inmuebles, y crear y actualizar agentes, devuelven un TransactionReceipt con el transactionId; el resultado definitivo llega al responseUrl del payload. Ver docs/task-polling.md y docs/webhooks.md.

Validación local

Los campos obligatorios se comprueban antes de gastar un request y fallan con InvalidArgumentException citando lo que falta:

PayloadValidator añade validación dirigida por OpenAPI (tipos, enums, requeridos anidados) en cuanto se disponga del snapshot oficial en resources/openapi/.

Testeabilidad

El cliente acepta un HttpClientInterface, un SchemaCatalog y un TokenProviderInterface inyectables, así que se instancia con dobles sin tocar nada privado ni la red:

Manejo de errores

Ver docs/error-handling.md.

Tests

La suite no realiza ninguna llamada de red.

Documentación

Soporte

Homlity no es Metrocuadrado: este SDK es un cliente independiente de su API pública. Las credenciales de integrador las entrega Metrocuadrado (ver docs/solicitud-acceso.md).

Licencia

MIT. Ver LICENSE.

Hecho por Homlity · homlity.com/desarrolladores


All versions of sdk-metrocuadrado with dependencies

PHP Build Version
Package Version
Requires php Version ^8.1
ext-curl Version *
ext-json Version *
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package homlity/sdk-metrocuadrado contains the following files

Loading the files please wait ...