gatsbyjs/gatsby · error · HttpError

${response.statusText}

Error message

${response.statusText}

What it means

graphqlFetch throws HttpError when the Shopify Admin API response is not ok and not retryable (status < 500 or backoff cap exceeded). 5xx responses are retried with exponential backoff first; this throw means a persistent client-side HTTP failure such as auth or bad request.

Source

Thrown at packages/gatsby-source-shopify/src/clients.ts:38

      method: `POST`,
      headers: {
        "Content-Type": `application/json`,
        "X-Shopify-Access-Token": options.password,
      },
      body: JSON.stringify({
        query,
        variables,
      }),
    })

    if (!response.ok) {
      const waitTime = 2 ** (retries + 1) + 500
      if (response.status >= 500 && waitTime < MAX_BACKOFF_MILLISECONDS) {
        await new Promise(resolve => setTimeout(resolve, waitTime))
        return graphqlFetch(query, variables, retries + 1)
      }

      throw new HttpError(response)
    }

    const json = await response.json()
    return json.data as T
  }

  return { request: graphqlFetch }
}

export function createRestClient(options: IShopifyPluginOptions): IRestClient {
  const baseUrl = `https://${options.storeUrl}/admin/api/${options.apiVersion}`

  async function shopifyFetch(
    path: string,
    fetchOptions = {
      headers: {
        "X-Shopify-Access-Token": options.password,
      },

View on GitHub (pinned to e85d62f177)

Solutions

  1. Check the Shopify access token and shop domain
  2. Inspect response.statusText for the concrete failure
  3. Reduce request rate if hitting Shopify throttling limits
Defensive patterns

Strategy: retry

When it happens

Trigger: Thrown at packages/gatsby-source-shopify/src/clients.ts:38 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of gatsbyjs/gatsby@e85d62f177 (2026-08-26). Data as JSON: /api/errors/dbf33daf0ccef3b5. Report an issue: GitHub.