.api-reports/api-report-errors.api.md
Do not edit this file. It is a report generated by API Extractor.
import type { ApolloLink } from '@apollo/client/link';
import { ErrorLike } from '@apollo/client';
import type { FormattedExecutionResult } from 'graphql';
import type { GraphQLFormattedError } from 'graphql';
// @public (undocumented)
export namespace CombinedGraphQLErrors {
// (undocumented)
export namespace DocumentationTypes {
export function formatMessage(errors: ReadonlyArray<GraphQLFormattedError>, options: MessageFormatterOptions): string;
// (undocumented)
export interface InstanceProperties {
readonly data: Record<string, unknown> | null | undefined;
readonly errors: ReadonlyArray<GraphQLFormattedError>;
readonly extensions: Record<string, unknown> | undefined;
}
export function is(error: unknown): boolean;
}
export type MessageFormatter = (errors: ReadonlyArray<GraphQLFormattedError>, options: MessageFormatterOptions) => string;
// (undocumented)
export interface MessageFormatterOptions {
defaultFormatMessage: (errors: ReadonlyArray<GraphQLFormattedError>) => string;
result: ApolloLink.Result<unknown>;
}
}
// @public
export class CombinedGraphQLErrors extends Error {
constructor(result: FormattedExecutionResult<any>);
constructor(result: ApolloLink.Result<any>, errors: ReadonlyArray<GraphQLFormattedError>);
readonly data: Record<string, unknown> | null | undefined;
readonly errors: ReadonlyArray<GraphQLFormattedError>;
readonly extensions: Record<string, unknown> | undefined;
static formatMessage: CombinedGraphQLErrors.MessageFormatter;
static is(error: unknown): error is CombinedGraphQLErrors;
}
// @public (undocumented)
export namespace CombinedProtocolErrors {
// (undocumented)
export namespace DocumentationTypes {
export function formatMessage(errors: ReadonlyArray<GraphQLFormattedError>, options: MessageFormatterOptions): string;
// (undocumented)
export interface InstanceProperties {
readonly errors: ReadonlyArray<GraphQLFormattedError>;
}
}
export type MessageFormatter = (errors: ReadonlyArray<GraphQLFormattedError>, options: MessageFormatterOptions) => string;
// (undocumented)
export interface MessageFormatterOptions {
defaultFormatMessage: (errors: ReadonlyArray<GraphQLFormattedError>) => string;
}
}
// @public
export class CombinedProtocolErrors extends Error {
constructor(protocolErrors: Array<GraphQLFormattedError> | ReadonlyArray<GraphQLFormattedError>);
readonly errors: ReadonlyArray<GraphQLFormattedError>;
static formatMessage: CombinedProtocolErrors.MessageFormatter;
static is(error: unknown): error is CombinedProtocolErrors;
}
// @public (undocumented)
export function graphQLResultHasProtocolErrors<T extends {}>(result: T): result is T & {
extensions: Record<string | symbol, any>;
};
// @public (undocumented)
export function isErrorLike(error: unknown): error is ErrorLike;
// @public
export const LinkError: {
is: (error: unknown) => boolean;
};
// @public (undocumented)
export namespace LocalStateError {
// (undocumented)
export namespace DocumentationTypes {
// (undocumented)
export interface InstanceProperties {
readonly path?: Array<string | number>;
}
}
// (undocumented)
export interface Options {
// (undocumented)
path?: Array<string | number>;
// (undocumented)
sourceError?: unknown;
}
}
// @public
export class LocalStateError extends Error {
constructor(message: string, options?: LocalStateError.Options);
static is(error: unknown): error is LocalStateError;
readonly path?: Array<string | number>;
}
// @public (undocumented)
export const PROTOCOL_ERRORS_SYMBOL: unique symbol;
// @internal @deprecated
export function registerLinkError(error: ErrorLike): void;
// @public (undocumented)
export namespace ServerError {
// (undocumented)
export namespace DocumentationTypes {
// (undocumented)
export interface InstanceProperties {
readonly bodyText: string;
readonly response: Response;
readonly statusCode: number;
}
}
// (undocumented)
export interface Options {
// (undocumented)
bodyText: string;
// (undocumented)
response: Response;
}
}
// @public
export class ServerError extends Error {
constructor(message: string, options: ServerError.Options);
readonly bodyText: string;
static is(error: unknown): error is ServerError;
readonly response: Response;
readonly statusCode: number;
}
// @public (undocumented)
export namespace ServerParseError {
// (undocumented)
export namespace DocumentationTypes {
// (undocumented)
export interface InstanceProperties {
readonly bodyText: string;
readonly response: Response;
readonly statusCode: number;
}
}
// (undocumented)
export interface Options {
// (undocumented)
bodyText: string;
// (undocumented)
response: Response;
}
}
// @public
export class ServerParseError extends Error {
constructor(originalParseError: unknown, options: ServerParseError.Options);
readonly bodyText: string;
static is(error: unknown): error is ServerParseError;
readonly response: Response;
readonly statusCode: number;
}
// @public (undocumented)
export function toErrorLike(error: unknown): ErrorLike;
// @public
export class UnconventionalError extends Error {
constructor(errorType: unknown);
static is(error: unknown): error is UnconventionalError;
}
// (No @packageDocumentation comment for this package)