public function __invoke(Request $request)
{
$documentation = new Documentation($this->resourceNameCollectionFactory->create(), $this->title, $this->description, $this->version, $this->formats);
return new Response($this->twig->render('ApiPlatformBundle:SwaggerUi:index.html.twig', $this->getContext($request) + ['spec' => $this->serializer->serialize($documentation, 'json')]));
}