answear / dpd-pl-pickup-services-bundle
DPD.pl Pickup Services integration for Symfony.
Installs: 15 196
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 3
Forks: 1
Open Issues: 0
Type:symfony-bundle
pkg:composer/answear/dpd-pl-pickup-services-bundle
Requires
- php: ^8.4
- ext-simplexml: *
- guzzlehttp/guzzle: ^7.8.2
- guzzlehttp/psr7: ^2.6
- symfony/http-kernel: ^7.0.3
- webmozart/assert: ^1.11
Requires (Dev)
- friendsofphp/php-cs-fixer: ^3.64
- phpro/grumphp: ^2.12
- phpstan/phpstan: ^2.1
- phpstan/phpstan-webmozart-assert: ^2.0
- phpunit/phpunit: ^10.5.27
- roave/security-advisories: dev-master
- symfony/phpunit-bridge: ^7.0.3
README
Integration for DPD.pl's PICKUP Services API avialble mypudo.dpd.com.pl.
Installation
- install with Composer
composer require answear/dpd-pl-pickup-services-bundle
Answear\DpdPlPickupServicesBundle\AnswearDpdPlPickupServicesBundle::class => ['all' => true],
should be added automatically to your config/bundles.php file by Symfony Flex.
Configuration
Below you will find bundle's full configuration:
answear_dpd_pl_pickup_services: key: 'xxxxxx' # your API Key # settings below are set as default, you don't need to provide them url: 'https://mypudo.dpd.com.pl/api/pudo/' # service's URL requestTimeout: 10.0 # time the library will wait for server's response
When using library without Symfony you need to put your configuration into an
instance of \Answear\DpdPlPickupServicesBundle\Service\ConfigProvider object.
Usage
DPD's API is available through two main services:
Answear\DpdPlPickupServicesBundle\Service\PUDOList- returns all PUDO items at onceAnswear\DpdPlPickupServicesBundle\Service\PUDOListStreaming- streams PUDO items one by one
Both services are automatically registered in your Symfony application's DI container. PUDO items
are returned to you as Answear\DpdPlPickupServicesBundle\ValueObject\PUDO objects.
Final notes
Feel free to open pull requests with new features, improvements or bug fixes. The Answear team will be grateful for any comments.