Join us from October 8-10 in New York City to learn the latest tips, trends, and news about GraphQL Federation and API platform engineering.Join us for GraphQL Summit 2024 in NYC
Docs
Start for Free

Router Errors

Error and status codes returned by GraphOS Router and Apollo Router Core


Learn about error codes and HTTP response status codes returned by and .

Status codes

CodeDescription
400
Bad request

A request failed validation or failed to be parsed.

401
Unauthorized

Requests may receive this response in two cases:

  • For a client request that requires authentication, the client's JWT failed verification.
  • For a non-client endpoint calling a subscription callback URL, the couldn't find a matching subscription identifier between its registered subscriptions and a subscription event.
405
Method not allowed

A request used an unallowed HTTP method.

NOTE

Both and must use POST.

406
Not acceptable

A request's HTTP Accept header didn't contain any of the router's supported mime-types:

  • application/json
  • application/graphql-response+json
  • multipart/mixed;deferSpec=20220824
  • multipart/mixed;subscriptionSpec=1.0.
429
Too many requests

Request traffic exceeded configured rate limits. See client side traffic shaping.

499
Request canceled by client

The request was canceled because the client closed the connection, possibly due to a client side timeout.

500
Internal server error

The router encountered an unexpected issue. Report this possible bug to the router team.

504
Request timed out

The request was not able to complete within a configured amount of time. See client side traffic shaping timeouts.

NOTE

You can create Rhai scripts that throw custom status codes. See Terminating client requests to learn more.

Error codes

Demand control

Errors returned by the router when demand control is enabled.

CodeDescription
COST_ESTIMATED_TOO_EXPENSIVE

The estimated cost of the was greater than the configured maximum cost.

COST_ACTUAL_TOO_EXPENSIVE

The actual cost of the query was greater than the configured maximum cost.

COST_QUERY_PARSE_FAILURE

The query could not be parsed.

COST_RESPONSE_TYPING_FAILURE

The response from a did not match the .

Previous
Entity Caching
Next
Telemetry
Rate articleRateEdit on GitHubEditForumsDiscord

Company