craftt / xorder-sdk
PHP SDK for Container World's xOrder EDI platform.
Requires
- php: >=5.5.9
- ext-dom: *
- guzzlehttp/guzzle: >=5.3|~6.0.1|~6.1
- guzzlehttp/psr7: ~1.0
- psr/http-message: ^1.0
- psr/log: ^1.0
Requires (Dev)
- illuminate/view: ^5.1
- mockery/mockery: ^0.9.4
- phpunit/phpunit: ~4.0
- squizlabs/php_codesniffer: *
Suggests
- ext-curl: Required to send requests using cURL.
- illuminate/view: Required to make the examples work.
- monolog/monolog: PSR-3 compatable logger.
This package is not auto-updated.
Last update: 2025-03-29 20:48:29 UTC
README
The xOrder PHP SDK makes it easy to integrate your order and inventory sytsems with ContainerWorld's xOrder EDI service. It leverages the powerful Guzzle library to make http requests.
Usage
Examples of how the xOrder PHP SDK can be used are located in the examples directory.
$xorder = new XOrder\XOrder('xorder.xml', true); $credentials = new XOrder\Credentials('username', 'password', 'account'); $client = new XOrder\Client; $client->login($credentials); $response = $client->send($xorder);
Order Validation
The xOrder PHP SDK can also be used to validate your order xml against the xOrder schema declaration.
$xorder = new XOrder\XOrder('xorder.xml', true); $validator = new XOrder\XOrderValidator($xorder); $isValid = $validator->validate();
Testing
The xOrder PHP SDK has a PHPUnit test suite. To run the tests, run the following command from the project folder:
$ phpunit
Contributing
Contributions are welcome and will be fully credited. Please see CONTRIBUTING for details.
Security
If you discover any security related issues, please email hello@craftt.com instead of using the issue tracker.
License
Apache 2.0. Please see LICENSE for more information.