Download the PHP package shelfwood/php-pms-clients without Composer
On this page you can find all versions of the php package shelfwood/php-pms-clients. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download shelfwood/php-pms-clients
More information about shelfwood/php-pms-clients
Files in shelfwood/php-pms-clients
Package php-pms-clients
Short Description PHP clients for various Property Management Systems (PMS) like Mews and Booking Manager.
License MIT
Informations about the package php-pms-clients
PHP PMS Clients
This repository contains PHP clients for Property Management Systems (PMS).
Supported Property Management Systems
- [x] BookingManager
- [x] Mews
Installation
Laravel Integration
Automatic Service Provider Registration
The package will automatically register its service provider in Laravel applications using auto-discovery.
Configuration Publishing
Publish the configuration file to customize HTTP client behavior:
This creates config/php-pms.php with the following options:
Environment Variables
Add these to your .env file:
Controlling Debug Output
The verbose HTTP debug output (cURL verbose mode) can be controlled via environment:
- Production/Staging: Debug output is always disabled for security
- Local Environment: Set
PHP_PMS_HTTP_DEBUG=trueto enable debug output - Default: Debug output is disabled by default
This prevents the verbose cURL output that appears in art queue:listen when APP_DEBUG=true.
Debugging
A CLI tool is included to help debug the BookingManager API integration using a production key. It runs a sequence of non-destructive read calls to verify data is being returned and mapped correctly.
The sequence is:
- Fetch all properties.
- Fetch details for a specific property (either the first one found or one you specify).
- Fetch calendar changes for the past week.
- Fetch the calendar/availability for that property for the next 30 days.
- Fetch a sample rate for a future stay at that property.
Usage:
Make the script executable:
Run the script with your API key:
Optionally, you can specify a property ID to test:
The script will output the parsed XML data and the final mapped PHP object for each step, which is useful for verifying that all data fields are correctly set up in the PMS.
Testing
The test suite uses Pest and employs a comprehensive Golden Master testing approach. For each API endpoint, we validate the entire response object against a canonical "golden" version, ensuring 100% of fields are mapped correctly for both rich and edge-case responses.
The testing strategy includes:
- Golden Master Validation: Each endpoint test validates every field in the response against expected data
- Edge Case Coverage: Tests for minimal properties, inactive properties, empty responses, and comprehensive data
- 485+ Assertions: Comprehensive validation covering all response object properties
- Curated Mock Data: Real-world XML responses extracted from production data for accurate testing
Test Structure:
tests/Endpoint/BookingManager/— Endpoint-level integration tests for BookingManager APItests/Helpers/— Reusable assertion helpers and test datamocks/bookingmanager/— Comprehensive mock XML responses including edge cases
Running Tests:
Project Structure
src/— Library source code, organized by PMS and concern.tests/Endpoint/BookingManager/— Endpoint-level integration tests for BookingManager API.mocks/— Mock XML responses for deterministic test scenarios.bin/— Executable CLI tools for debugging and other tasks.
All versions of php-pms-clients with dependencies
fakerphp/faker Version ^1.24
guzzlehttp/guzzle Version ^7.9
illuminate/support Version ^10.0|^11.0|^12.0
nesbot/carbon Version ^3.9
psr/log Version ^3.0