Error Tracking

The Stellate Error tracking functionality allows you to recreate errors in the system by providing detailed information about the error paths and error codes. By analyzing GraphQLErrors, you can identify specific issues within their queries and optimize the user interface accordingly.

GraphQL, typically used over HTTP but not reliant on it, doesn't use HTTP error codes, except for HTTP layer errors. This affects how you manage error handling. Stellate Error tracking is designed to overcome such challenges in managing your GraphQL errors. Stellate Error tracking does this, in part, by looking at the shape of the GraphQL Error and using path , message and extensions.code for each one on a given request.

Improved GraphQL Error Experience

With Error Replay, the Stellate Dashboard Errors page defaults to grouping errors by Error Code, providing insight into error volume for a given time frame. This can provide context more quickly for your errors and enhance your overall error experience. Error Replay includes:

  • Stellate Error Aggregation: To provide context more quickly for errors, Stellate Error Replay features support for error codes and error aggregation.
  • Aggregation Error Page: The Stellate Dashboard Errors page defaults to grouping errors by error code, providing insight into error volume for a given time frame. Also included is the operation triggering the error and the error path.
  • Error Event Details: For each aggregated error, you can dive into the individual error events to assess the state and specific error message of each one.

Benefits of Error Tracking

The Stellate Error Replay feature offers the following benefits:

  • Improved Usability: Enhances error functionality to make it more user-friendly and actionable.
  • Instant Context: Provides instant context on the impact of errors, helping users understand the severity and scale of the issue.
  • Client Representation: Offers a first-class client representation of errors, enabling better understanding and management of errors.

Before You Begin

Before using our error tracking functionality, you might check that error paths and error codes are properly configured within your GraphQL schema.

Familiarize yourself with the GraphQLError structure and how to interpret error messages for effective error replay. You also need to opt into Error Replay to use it

Analyze GraphQL Errors with Error Replay

Once you have opted into using Error Replay, you can effectively, analyze the error paths and error codes provided in the GraphQLErrors object. You can utilize the information to recreate errors, debug issues, and optimize the user interface based on the identified errors. To get started:

  1. Navigate to your Stellate Services and click on the Service that you want to work with.
  2. Click on Errors in the left sidebar.
  3. Review the Error Event graph
  4. To see errors:
    1. By a specific time frame, select the Calendar icon or the Time Menu in the upper right. You can select specific time frames from 15 minutes to 30 days.
    2. By category, select Filter and click on a specific category you want to view.
  5. To see aggregated errors with their error code and path go to the detail view beneath the graph.
  6. Select one of the aggregate errors to view a panel with error details.

By understanding and referencing these error details, you can effectively troubleshoot and address issues within your GraphQL application.

Error Tracking

Stellate Error tracking boosts your ability to debug errors by giving you visibility into your errors and the ability to extend your GraphQL query to add your own error codes, as detailed in the following section. Your error debugging would follow this kind of process:

  1. You become aware of an error and find the error using the Stellate Dashboard, either through search or by clicking your error email link.
  2. You view the Error Event page to see the error query. Errors are aggregated on this page, by error code, with the ability to dive into individual error events.
  3. You can see the output of the query and analyze the results to identify details about your error for easier debugging. Details include the:
    1. Impact of the error by user.
    2. Impact by client version.

Adding Error Codes

You need to add error codes to see the error code results. To add new error codes you can:

  1. Throw new GraphQL error and give it a message. For example:

    throw new GraphQL error (ā€˜simulated errorā€™);
  2. When we query this error it shows the simulated error message with the associated path products. However, this will be missing the code. Here is an example:

  "data": null,
	"errors": [{
		"message": "Simulated error",
		"locations": [{
			"line": 2,
			"column": 3
		"path": [
		"extensions": {
			"code": "SIMULATED_ERROR"
  1. You need to create some extensions to add the code and message. In our example the message is ā€œsimulated errorā€.
import { GraphQLError } from 'graphql';

throw new GraphQLError(ā€˜simulated errorā€™, {
	extensions : [

Once you introduce the extension code, the Error Event page and aggregated errors can dispaly the extensions code. In our example the error display shows SIMULATED ERROR. This is by default included on the GraphQL error.

Error Terms

  • Error: the This term refers to a ā€œrolled-upā€ error; a set of related error events
  • Error Events: This term refers to individual error occurrences. An individual error has 1..n events.
  • ErrorResponse object: contains key information such as: the operations that have errors, the response execution details, an array of errors from the GraphQL endpoint, and any network errors encountered during execution.

Discover more