GraphQL Query Issue with Strapi Comments Plugin

Hello, Strapi Community!

I’m fairly new to Strapi and currently facing an issue with implementing the Strapi Comments Plugin on my website. I aim to add a comments section and manage it using GraphQL queries for fetching and posting comments. Despite my efforts, I’ve hit a roadblock while testing in the GraphQL playground.

Here’s the query I attempted:

query {
  findAllFlat(
    relation: "api::page.page:1"
    filters: { content: { contains: "Test" } }
  ) {
    id
    content
    blocked
    threadOf {
      id
    }
    author {
      id
      name
    }
  }
}

I encountered an error stating: “Cannot query field ‘findAllFlat’ on Type Query.” I’ve ensured that all actions related to the comments plugin are accessible to the public through the USERS & PERMISSIONS PLUGIN, yet the issue persists.


Could someone shed light on what might be causing this error and how to resolve it? Any guidance or suggestions would be immensely appreciated. Thank you in advance for your support!