{"record":{"id":"52036d039730ea52","repo":"gatsbyjs/gatsby","slug":"fetchtags","errorCode":"FetchTags","errorMessage":"Error fetching tags: ${createContentfulErrorMessage(e)}","messagePattern":"Error fetching tags: (.+?)","errorType":"panic","errorClass":null,"httpStatus":null,"severity":"error","filePath":"packages/gatsby-source-contentful/src/fetch.js","lineNumber":354,"sourceCode":"      !currentSyncData?.deletedEntries.length &&\n      !currentSyncData?.deletedAssets.length\n    ) {\n      syncProgress.tick()\n      syncProgress.total = 1\n    }\n\n    syncProgress.done()\n  }\n\n  // We need to fetch tags with the non-sync API as the sync API doesn't support this.\n  let tagItems = []\n  if (pluginConfig.get(`enableTags`)) {\n    try {\n      const tagsResult = await pagedGet(client, `getTags`, pageLimit)\n      tagItems = tagsResult.items\n      reporter.verbose(`Tags fetched ${tagItems.length}`)\n    } catch (e) {\n      reporter.panic({\n        id: CODES.FetchTags,\n        context: {\n          sourceMessage: `Error fetching tags: ${createContentfulErrorMessage(\n            e\n          )}`,\n        },\n      })\n    }\n  }\n\n  const result = {\n    currentSyncData,\n    tagItems,\n    defaultLocale,\n    locales,\n    space,\n  }\n","sourceCodeStart":336,"sourceCodeEnd":372,"githubUrl":"https://github.com/gatsbyjs/gatsby/blob/8b06340921ffdf23125a365b9c9923690cb62ce6/packages/gatsby-source-contentful/src/fetch.js#L336-L372","documentation":"Error \"Error fetching tags: ${createContentfulErrorMessage(e)}\" thrown in gatsbyjs/gatsby.","triggerScenarios":"Thrown at packages/gatsby-source-contentful/src/fetch.js:354 when the library encounters an invalid state.","commonSituations":"Occurs when fetching tags from the Contentful API fails. Check network connectivity and that the access token has permission to read tags in the target environment.","solutions":["Verify the Contentful access token has permission to read tags for the space/environment.","Check the space ID and environment in plugin options, then retry the build."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"8b06340921ffdf23125a365b9c9923690cb62ce6","analyzedAt":"2026-08-13T02:36:21.405Z","schemaVersion":2},"datasetVersion":"2026-08-13T04:17:16.726Z"}