Is it possible to get tagList in AEM using GraphQL API? | Community
Skip to main content
Level 4
September 26, 2022
Solved

Is it possible to get tagList in AEM using GraphQL API?

  • September 26, 2022
  • 1 reply
  • 886 views

I want to fetch all the available tags under a given folder. Is it possible to perform the same using GQL API or would I need QueryBuilder or Assets API for the same?

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Saravanan_Dharmaraj

I don't think we can use GQL to fetch the tags like we use QueryBuilder API. I think AEM GQL API is very specific to query the content fragments by its schema. May be Adobe guys can chime in and confirm. Sorry for the confusion!

Some insight here : https://www.albinsblog.com/2022/04/aem-adobe-experience-manager-content-sharing-approaches.html#.YzLvLeyZMV8 

1 reply

Saravanan_Dharmaraj
Community Advisor
Community Advisor
September 27, 2022

You can write simple query using querybuilder API and read all the tags under a specific path. 

 

path=<path of the folder>

p.limit=-1

type=cq:tag

 

 

 

Level 4
September 27, 2022

thank you very much @saravanan_dharmaraj I know we can do it via queryBuilder however I was checking for the possibility of querying the same using GQL. Thanks 🙂

Saravanan_Dharmaraj
Community Advisor
Saravanan_DharmarajCommunity AdvisorAccepted solution
Community Advisor
September 27, 2022

I don't think we can use GQL to fetch the tags like we use QueryBuilder API. I think AEM GQL API is very specific to query the content fragments by its schema. May be Adobe guys can chime in and confirm. Sorry for the confusion!

Some insight here : https://www.albinsblog.com/2022/04/aem-adobe-experience-manager-content-sharing-approaches.html#.YzLvLeyZMV8