DependencyInjection/Configuration.php
public function getConfigTreeBuilder()
    {
        $treeBuilder = new TreeBuilder();
        $rootNode = $treeBuilder->root('ongr_api');

        $rootNode
            ->children()
                ->arrayNode('versions')
                    ->info('Defines api versions.')
                    ->useAttributeAsKey('version')
                    ->prototype('array')
                    ->children()
                        ->scalarNode('versions')
                            ->info('Defines a version for current api endpoints.')
                            ->example('v1')
                            ->end()
                        ->append($this->getEndpointNode())
                        ->end()
                ->end()
            ->end();

        return $treeBuilder;
    }
public function getConfigTreeBuilder()
    {
        $treeBuilder = new TreeBuilder();
        $rootNode = $treeBuilder->root('ongr_api');

        $rootNode
            ->children()
                ->arrayNode('versions')
                    ->info('Defines api versions.')
                    ->useAttributeAsKey('version')
                    ->prototype('array')
                    ->children()
                        ->scalarNode('versions')
                            ->info('Defines a version for current api endpoints.')
                            ->example('v1')
                            ->end()
                        ->append($this->getEndpointNode())
                        ->end()
                ->end()
            ->end();

        return $treeBuilder;
    }
{@inheritdoc}