plugin/blog/Controller/API/BlogController.php
public function getTagsAction(Blog $blog)
    {
        $this->checkPermission('OPEN', $blog->getResourceNode(), [], true);

        $parameters['limit'] = -1;
        $posts = $this->postManager->getPosts(
            $blog->getId(),
            $parameters,
            $this->checkPermission('ADMINISTRATE', $blog->getResourceNode())
            || $this->checkPermission('EDIT', $blog->getResourceNode())
            || $this->checkPermission('MODERATE', $blog->getResourceNode())
                ? PostManager::GET_ALL_POSTS
                : PostManager::GET_PUBLISHED_POSTS,
            true);

        $postsData = [];
        if (!empty($posts)) {
            $postsData = $posts['data'];
        }

        return new JsonResponse($this->blogManager->getTags($blog, $postsData));
    }
public function getTagsAction(Blog $blog)
    {
        $this->checkPermission('OPEN', $blog->getResourceNode(), [], true);

        $parameters['limit'] = -1;
        $posts = $this->postManager->getPosts(
            $blog->getId(),
            $parameters,
            $this->checkPermission('ADMINISTRATE', $blog->getResourceNode())
            || $this->checkPermission('EDIT', $blog->getResourceNode())
            || $this->checkPermission('MODERATE', $blog->getResourceNode())
                ? PostManager::GET_ALL_POSTS
                : PostManager::GET_PUBLISHED_POSTS,
            true);

        $postsData = [];
        if (!empty($posts)) {
            $postsData = $posts['data'];
        }

        return new JsonResponse($this->blogManager->getTags($blog, $postsData));
    }
public function getTagsAction ( Blog $ blog ) { $ this -> checkPermission ( 'OPEN' , $ blog -> getResourceNode ( ) , [ ] , true ) ; $ parameters [ 'limit' ] = - 1 ; $ posts = $ this -> postManager -> getPosts ( $ blog -> getId ( ) , $ parameters , $ this -> checkPermission ( 'ADMINISTRATE' , $ blog -> getResourceNode ( ) ) || $ this -> checkPermission ( 'EDIT' , $ blog -> getResourceNode ( ) ) || $ this -> checkPermission ( 'MODERATE' , $ blog -> getResourceNode ( ) ) ? PostManager :: GET_ALL_POSTS : PostManager :: GET_PUBLISHED_POSTS , true ) ; $ postsData = [ ] ; if ( ! empty ( $ posts ) ) { $ postsData = $ posts [ 'data' ] ; } return new JsonResponse ( $ this -> blogManager -> getTags ( $ blog , $ postsData ) ) ; }
Get tag cloud, tags used in blog posts.

@EXT\Route("tags", name="apiv2_blog_tags")
@EXT\Method("GET")
Get tag cloud tags used in blog posts .