resources:
    App\Entity\Command:
        processor: App\State\Processor\CommandProcessor
        input: App\Dto\Input\CommandInput
        output: App\Dto\Output\CommandOutput
        normalizationContext:
            groups: ['default', 'command:read']
        denormalizationContext:
            groups: ['command:write']
        order:
            id: 'DESC'
        operations:
            ApiPlatform\Metadata\GetCollection:
                provider: App\State\Provider\CommandProvider
                filters:
                    - 'api_platform.filter.command.order'
                    - 'api_platform.filter.command.search'
                    - 'api_platform.filter.command.boolean'

            ApiPlatform\Metadata\Get:
                provider: App\State\Provider\CommandProvider
            ApiPlatform\Metadata\Put:
                provider: App\State\Provider\CommandProvider
            ApiPlatform\Metadata\Patch:
                provider: App\State\Provider\CommandProvider
            ApiPlatform\Metadata\Post: ~
            ApiPlatform\Metadata\Delete: ~

            command_execute:
                class: ApiPlatform\Metadata\Post
                method: POST
                input: App\Dto\Input\CommandExecuteInput
                uriTemplate: /commands/run-script
                controller: App\Controller\OgAgent\RunScriptAction
properties:
    App\Entity\Command:
        id:
            identifier: false
        uuid:
            identifier: true