alexandrebulete / ddd-apiplatform-bundle
Symfony Bundle for DDD API Platform Bridge - Service wiring and configuration
Installs: 0
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 0
Forks: 0
Open Issues: 0
Type:symfony-bundle
pkg:composer/alexandrebulete/ddd-apiplatform-bundle
Requires
- php: ^8.2
- alexandrebulete/ddd-apiplatform-bridge: ^1.0
- symfony/config: ^7.0
- symfony/dependency-injection: ^7.0
- symfony/framework-bundle: ^7.0
This package is auto-updated.
Last update: 2026-01-26 23:46:14 UTC
README
Symfony Bundle for the DDD API Platform Bridge. Provides service wiring and configuration for API Platform integration.
Installation
composer require alexandrebulete/ddd-apiplatform-bundle
Configuration
Add the bundle to your config/bundles.php:
return [ // ... AlexandreBulete\DddApiPlatformBundle\DddApiPlatformBundle::class => ['all' => true], ];
Features
This bundle automatically registers services from ddd-apiplatform-bridge:
Paginatoravailable for use in your State Providers
Usage
Create your own State Providers using the Paginator:
use AlexandreBulete\DddApiPlatformBridge\State\Paginator; use ApiPlatform\Metadata\Operation; use ApiPlatform\State\ProviderInterface; class GetPostsProvider implements ProviderInterface { public function __construct( private QueryBusInterface $queryBus, ) {} public function provide(Operation $operation, array $uriVariables = [], array $context = []): object|array|null { $posts = $this->queryBus->ask(new GetPostsQuery(/* ... */)); // Return Paginator for pagination support return new Paginator(/* ... */); } }