Skip to content

[admin-api-client] Intermittent "GraphQL Client: Not Found" 404 — is this a known SDK / undici interaction? #3255

Description

@saeedeldeeb

What we're seeing

In production we occasionally get this from @shopify/admin-api-client:

Received an error response (404 Not Found) from Shopify:
{
  "networkStatusCode": 404,
  "message": "GraphQL Client: Not Found",
  "response": {}
}

It hits multiple stores in clusters, then stops. The same shop / order / token / API version path returns 200 if we curl it directly from the same host while the SDK is 404'ing, and restarting the Node process makes the errors stop for hours. Affects orderUpdate, orderCancel, order(id) queries.

Our guess (would love confirmation or correction)

It looks like it might be the undici keep-alive socket reuse pattern from
nodejs/undici#1415 and nodejs/node#47130 — stale sockets in the pool getting routed to a different edge backend after a rotation. But we're not sure if that's actually what's happening here or if we're using the SDK wrong.

Questions

  1. Is this a known issue with admin-api-client? We saw a similar-shaped report in admin-api-client + node-fetch erroring since a few days: Client network socket disconnected before secure TLS connection was established #1851 but didn't find anything confirming this exact 404 shape is the same root cause.
  2. If it is the undici pool, would you recommend a customFetchApi with a tuned Agent as the right workaround? Is there a preferred pattern?
  3. The current retries option excludes 404 — is that intentional, or would including this specific "GraphQL Client: Not Found" shape (which is the wrapper's signal for an empty-body transport 404) be in scope?
  4. Anything we should be checking on our side before assuming it's an SDK issue?

Environment

  • @shopify/admin-api-client 1.1.1, @shopify/shopify-api 12.3.0
  • Node 24.16.0 (bundled undici 7.25.0)
  • API version 2026-01

Happy to share more details / repro if useful.

Metadata

Metadata

Assignees

No one assigned

    Labels

    devtools-gardenerPost the issue or PR to Slack for the gardener

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions