# @graphql-inspector/core

> Tooling for GraphQL. Compare GraphQL Schemas, check documents, find breaking changes, find similar types.

Latest version **8.0.0** (published 2026-08-20) · MIT license · 0 weekly downloads

## Install

```sh
npm install @graphql-inspector/core
pnpm add @graphql-inspector/core
yarn add @graphql-inspector/core
bun add @graphql-inspector/core
```

## Health

**Score 70/100 (B)** — status: active.

Positive: has types; esm support; no vulnerabilities; has provenance; recently updated; high maintenance score.

Warnings: low downloads.

## Facts

| | |
|---|---|
| Version | 8.0.0 |
| Published | 2026-08-20 |
| First published | 2018-11-23 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Node | >=18.0.0 |
| Dependencies | 3 |
| Unpacked size | 652 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Provenance | attested (GitHub Actions) |
| GitHub stars | 1767 |
| Author | Kamil Kisiela |
| Maintainers | kamilkisiela, ardatan, n1ru4l, theguild-bot |
| Keywords | graphql, graphql-inspector, tools |

## Links

- npm: https://www.npmjs.com/package/@graphql-inspector/core
- Repository: https://github.com/graphql-hive/graphql-inspector
- Homepage: https://github.com/graphql-hive/graphql-inspector#readme
- Issues: https://github.com/graphql-hive/graphql-inspector/issues
- npm.io page: https://npm.io/package/@graphql-inspector/core

## Dependencies (3)

- [tslib](https://npm.io/package/tslib.md) ~2.6.2
- [object-inspect](https://npm.io/package/object-inspect.md) ^1.13.2
- [dependency-graph](https://npm.io/package/dependency-graph.md) ^1.0.0

## Alternatives

- [apollo-link-http-common](https://npm.io/package/apollo-link-http-common.md) — 879.0K weekly downloads
- [react-relay](https://npm.io/package/react-relay.md) — 336.8K weekly downloads
- [relay-test-utils](https://npm.io/package/relay-test-utils.md) — 181.6K weekly downloads
- [@vendure/core](https://npm.io/package/@vendure/core.md) — 14.8K weekly downloads
- [@pnpm/deps.graph-sequencer](https://npm.io/package/@pnpm/deps.graph-sequencer.md) — 13.4K weekly downloads

## Recent versions

- 8.0.0 (latest) — 2026-08-20
- 7.1.3-alpha-20260430181300-3f7cae7c1e580dc6c3e9327b1923ccb6927fbed9 (alpha) — 2026-04-30
- 0.0.0-canary.7db8980 (canary) — 2022-09-02
- 0.0.0-experimental.5431780 (experimental) — 2021-05-05
- 2.0.0-rc.2 (next) — 2020-04-21
- 7.1.3 — 2026-04-30
- 7.1.3-alpha-20260424210124-e75cd3af7eedf5c21f6e26f386e6e07a74acb9f4 — 2026-04-24
- 7.1.2 — 2026-01-26
- 7.1.2-alpha-20260126170535-bb28ee1994278c58fb986d032e9a493346e4d5f3 — 2026-01-26
- 7.1.2-alpha-20260123225001-24881d923593e4baadec9de367d6b34c1849820a — 2026-01-23
- 7.1.1 — 2026-01-22
- 7.1.1-alpha-20260122205327-9a3b84ad556f65419f1383789e4762528331f61c — 2026-01-22
- 7.1.1-alpha-20260121180707-eb09941cd292b5c7c0a7526b9ceee77d69591952 — 2026-01-21
- 7.1.1-alpha-20260116215327-8f3e542470887f46f0233526140738f2d38f091c — 2026-01-16
- 7.1.0 — 2025-12-10
- … 836 more at https://npm.io/package/@graphql-inspector/core/versions

## README

# GraphQL Inspector

[![CircleCI](https://circleci.com/gh/graphql-hive/graphql-inspector.svg?style=shield&circle-token=d1cd06aba321ee2b7bf8bd2041104643639463b0)](https://circleci.com/gh/graphql-hive/graphql-inspector)
[![npm version](https://badge.fury.io/js/@graphql-inspector/core.svg)](https://npmjs.com/package/@graphql-inspector/core)

**GraphQL Inspector** outputs a list of changes between two GraphQL schemas. Every change is
precisely explained and marked as breaking, non-breaking or dangerous. It helps you validate
documents and fragments against a schema and even find similar or duplicated types.

## Features

Major features:

- **Compares schemas**
- **Finds breaking or dangerous changes**
- **Validates documents against a schema**
- **Finds similar / duplicated types**
- **Schema coverage based on documents**
- **Serves a GraphQL server with faked data and GraphQL Playground**

GraphQL Inspector has a **CLI** and also a **programmatic API**, so you can use it however you want
to and even build tools on top of it.

## Installation

```bash
pnpm add @graphql-inspector/core
```

## Examples

```typescript
import {
  diff,
  validate,
  similar,
  coverage,
  Change,
  InvalidDocument,
  SimilarMap,
  SchemaCoverage
} from '@graphql-inspector/core'

// diff
const changes: Change[] = diff(schemaA, schemaB)
// validate
const invalid: InvalidDocument[] = validate(documentsGlob, schema)
// similar
const similar: SimilarMap = similar(schema, typename, threshold)
// coverage
const schemaCoverage: SchemaCoverage = coverage(schema, documents)
// ...
```

## License

[MIT](https://github.com/graphql-hive/graphql-inspector/blob/master/LICENSE) © Kamil Kisiela

---
_Source: https://npm.io/package/@graphql-inspector/core · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
