mpluskassa / mplusqapi
PHP Client for the MplusKASSA SOAP API
v1.60.2
2025-05-09 13:51 UTC
Requires
- php: >=8.0
- brick/math: ^0.9 || ^0.10 || ^0.11 || ^0.12
- guzzlehttp/guzzle: ^7.3
README
This is the official PHP client for the MplusKASSA SOAP API.
composer require mpluskassa/mplusqapi
Usage
use MplusKASSA\MplusQapi\MplusApiClient; $client = new MplusApiClient('api.mpluskassa.nl', $port, $ident, $secret); $response = $client->getApiVersion(); echo "{$response->serviceMajorNumber}.{$response->serviceMinorNumber}.{$response->serviceRevisionNumber}";
Debugging
To retrieve the raw SOAP XML contents of the last request and/or response that were sent, use getLastRequest
and getLastReponse
.
// ... $response = $client->getApiVersion(); $lastRequest = $client->getLastRequest(); echo $lastRequest; $lastResponse = $client->getLastResponse(); echo $lastResponse;
Features and Goals
- No runtime WSDL parsing needed.
- Strict typing.
- Increased productivity.
Notes on how the WSDL is mapped to PHP
- xsd:Date and xsd:DateTime are mapped to \DateTime
- xsd:Decimal is mapped to Brick\BigDecimal
- SoapMplusData and SoapMplusDataTime are converted to \DateTime
- Many longs that contain an unscaled value and their companion decimalplaces are converted to Brick\BigDecimal
- When a list is wrapped in an object containing only that list one level of indirection is removed
Dependencies
- guzzlehttp/guzzle
- brick/math