nodejs icon indicating copy to clipboard operation
nodejs copied to clipboard

Fetched categories length different from commerce tools dasboard

Open creotip opened this issue 3 years ago • 0 comments

Trying to get all existing categories with the following method:

  async getAllCategories() {
    try {
      const response = await this.apiRoot
        .withProjectKey({ projectKey: this.projectKey })
        .categories()
        .get()
        .execute()
      return response.body.results
    } catch (e) {
      console.log(e)
      throw e
    }
  }

I'm getting 19 categories. But in the admin dashboard i have 40 categories

creotip avatar Feb 15 '21 10:02 creotip